How to Fix Mixed Content Warnings on HTTPS Websites
Identify insecure HTTP assets, scripts, and fonts that trigger browser security warnings.
Mixed content occurs when an initial HTML document is loaded securely over HTTPS, but subsequent resources (scripts, stylesheets, images, iframes) are requested over unencrypted HTTP. Browsers block active mixed content to prevent man-in-the-middle code injection.
Root Cause Analysis
Hardcoded 'http://' URLs inside database entries, stylesheet assets, script tags, or third-party tracking beacons.
Step-by-Step Resolution Procedure
Run the Website Asset & Font Scanner to find hardcoded 'http://' asset URLs.
Add a Content Security Policy header instructing browsers to upgrade all HTTP requests to HTTPS automatically.
Search and replace hardcoded HTTP URLs with protocol-relative (//) or HTTPS URLs in your CMS.
Verification Command or Config Pattern
<!-- In HTML Head -->
<meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests">
<!-- Or via HTTP Header -->
Content-Security-Policy: upgrade-insecure-requests; default-src https: 'unsafe-inline' 'unsafe-eval';Frequently Asked Remediation Questions
What is passive vs active mixed content?
Passive mixed content includes images and audio/video files. Active mixed content includes scripts, stylesheets, and iframes, which browsers block completely because they can alter page behavior.
Does the padlock disappear with mixed content?
Yes. Browsers display a warning or broken padlock icon, eroding user trust and eCommerce conversions.
Does upgrade-insecure-requests work on all browsers?
Yes. Modern versions of Chrome, Safari, Firefox, and Edge all support the 'upgrade-insecure-requests' CSP directive.
How do I scan for mixed content?
Use the Redirect & Asset scanners on OnChainScans to identify unencrypted subresources.
Complementary Diagnostic Scanners
All 34 toolsWCAG Accessibility & Contrast Scanner
Audits foreground/background luminosity contrast ratios against WCAG 2.2 AA (4.5:1) and AAA (7:1) thresholds, detecting missing alt attributes and keyboard traps.
Robots.txt & Sitemap.xml Scanner
Verifies syntax of robots.txt files, parses nested sitemap_index.xml structures, and audits for broken URLs, conflicting directives, and 404 indexing errors.
Website Font, Color & Asset Scanner
Crawls live stylesheets to extract distinct hex color palettes, webfont load methods (WOFF2/FOUT metrics), and total uncompressed asset payload distribution.
Related Troubleshooting & RFC Playbooks
How to Fix SPF PermError: 'Too Many DNS Lookups' (RFC 7208)
Resolve the 10-lookup limit that causes receiving mail servers (Gmail, Outlook) to reject your emails.
How to Fix NET::ERR_CERT_AUTHORITY_INVALID SSL Handshake Errors
Repair broken intermediate certificate bundles and establish a trusted X.509 chain of trust.
How to Fix ERR_TOO_MANY_REDIRECTS & Circular Redirect Loops
Diagnose infinite HTTP 301/302 redirects between Cloudflare Flexible SSL, Nginx, and CMS canonical rules.