Console: Refused to apply style from 'https://…/style.css' because its MIME type ('text/html') is not a supported stylesheet MIME type
The stylesheet URL returned something that is not CSS — usually a 404/HTML error page — and X-Content-Type-Options: nosniff makes the browser refuse to treat it as CSS.
Refused to apply style fromis not a supported stylesheet MIME typeMIME type ('text/html') is not a supported stylesheet MIME typeand strict MIME checking is enabled Meaning
The request for the CSS file got an HTML document (an error page, a login page or your SPA's index.html fallback). Fix the URL or server route so the real CSS is served with Content-Type: text/css.
Common causes
- Wrong path to the CSS file (404 turned into index.html by SPA rewrite)
- Server returning an HTML error or login page for the file
- Wrong
Content-Typefor .css files - CDN or build step not deployed
- Rewrite rules catching static files
⚡ Quick fix
- Open the CSS URL in a new tab — is it CSS or HTML?
- Fix the
hrefpath or deploy the missing file - Serve
.cssastext/cssand exclude static paths from SPA rewrites
Detailed fix by platform
Nginx
- Ensure
include mime.types;andtry_files $uri =404;for static locations so missing files do not fall back toindex.html
Apache
AddType text/css .cssand add a rewrite conditionRewriteCond %{REQUEST_FILENAME} !-fbefore the SPA fallback
JavaScript
- In Vite/Webpack check
base/publicPathso asset URLs match where files are served
How to diagnose
- Response — HTML or CSS at the URL?
- Path — Correct base path?
- Rewrite — SPA fallback swallowing 404s?
🔧 Still not fixed?
Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:
Similar errors
- 404 HTTP 404 Not Found
- Aw, Snap! Chrome: Aw, Snap! Something went wrong while displaying this webpage. Error code: STATUS_ACCESS_VIOLATION / SIGILL / Out of Memory
- DevTools failed to load source map DevTools: Failed to load source map — Could not load content for https://…/app.js.map: HTTP error: status code 404
Most viewed in Browser
Other ways to find it
Where this error sits
Origin: On your device. Errors that are often confused with or caused by this one (click to open):
🧠 Still stuck? Analyze your error
Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.
💬 What worked for others
No tips yet — did something else fix this for you?
Share what worked for you
Tips are checked by an editor before they appear. Links are removed.
Report a correction or suggest an improvement
Last updated 15 Oct 2026