Software⏱️ 3 min read📅 2026-06-11

How to Fix: All pages under 'https://github.com' result in a 'Refused to load the stylesheet' error in Chrome

Chrome error message indicates Content Security Policy violation due to mismatched mime types, while Internet Explorer error suggests CSS ignored due to type mismatch.

Quick Answer: Try updating Chrome or disabling Content Security Policy (CSP) for the specific domain to resolve the issue.

The 'Refused to load the stylesheet' error in Chrome occurs when the browser is unable to load CSS styles from a specific website, in this case, any page under the github.com domain. This issue affects only a specific laptop and has been observed on devices connected to the same network.

This frustrating error can be caused by various factors, including incorrect DNS settings or a malfunctioning browser extension. Fortunately, there are steps you can take to resolve the issue and regain access to CSS styles.

🛑 Root Causes of the Error

  • The primary cause of this error is likely due to an incorrect Content Security Policy (CSP) configuration on your laptop's Chrome browser. The CSP directive 'style-src' is set to allow loading of inline styles from github.githubassets.com, but the browser is unable to load the stylesheet due to a mime type mismatch.
  • Another possible cause could be a DNS resolution issue or a malfunctioning browser extension that affects the ability to load CSS styles.

✅ Best Solutions to Fix It

Resetting Chrome's Content Security Policy

  1. Step 1: Open Chrome and navigate to chrome://settings/
  2. Step 2: Click on 'Advanced' and then scroll down to the 'Content settings' section.
  3. Step 3: Under 'Permissions', click on 'Site settings' next to 'github.com'.
  4. Step 4: Select 'Allow all sites to load stylesheets' and then click 'Save'.

Disabling browser extensions

  1. Step 1: Open Chrome and navigate to chrome://extensions/
  2. Step 2: Enable the 'Developer mode' by toggling the switch in the top-right corner.
  3. Step 3: Find the extension 'Adblock Plus' and toggle its switch to disable it.
  4. Step 4: Restart Chrome after disabling the extension.

🎯 Final Words

By resetting Chrome's Content Security Policy or disabling browser extensions, you should be able to load CSS styles from github.com. If the issue persists, consider checking your laptop's DNS settings and ensuring that all necessary updates are installed on your device.

Did this fix your problem?

If not, try searching for specific error codes.

🔍 Search Error Database

❓ Frequently Asked Questions