Resource interpreted as Stylesheet but transferred with MIME type text/javascript

I had the exact same problem, cause by lines in my HTML in the following form:

<link rel="stylesheet" type="text/css" href="css/my_css_resource.css" />

The problem was fixed when I removed rel="stylesheet" from the tag.


I realized that with my new Windows 10 machine, I'd failed to enable Static Content in my local IIS. To do so, go to "Turn Windows Features On or Off" from your Control Panel, and navigate to the following location:

enter image description here

Make sure this "Static Content" option is checked. Then, bring up a command window as an administrator and perform an iisreset.

Boom, fixed.


I had this same issue and it was due to using the wrong method to create the bundle. I carelessly copied a script bundle code and replaced it with CSS. Make sure you use StyleBundle for CSS and ScriptBundle for JS. Same with when you render it. Styles.Render() and Scripts.Render().

I had this:

bundles.Add(new ScriptBundle("~/bundles/bootstrap-core-css").Include("~/Content/themes/bootstrap/css/bootstrap.min.css"));

I changed to:

bundles.Add(new StyleBundle("~/bundles/bootstrap-core-css").Include("~/Content/themes/bootstrap/css/bootstrap.min.css"));

I hope this helps.