Newwebs Techs logo Newwebs TechsBuilding websites, explained for beginners
Maintenance and Security

How to Fix Mixed Content Warnings After Moving to HTTPS

You installed an SSL certificate, your site now loads over HTTPS, and yet the browser still shows a warning icon or a "not fully secure" message next to the address bar.

A laptop on a desk showing a browser developer console with yellow warning lines, next to a notebook with a handwritten checklist

You installed an SSL certificate, your site now loads over HTTPS, and yet the browser still shows a warning icon or a "not fully secure" message next to the address bar. Mixed content warnings are the usual cause, and they mean some part of your page is still being loaded over plain HTTP.

This is one of the most common problems after moving a small site to HTTPS, and it is almost always fixable in under an hour. Below I explain what mixed content is, how to find every insecure item on your pages, and how to fix mixed content warnings properly rather than hiding them.

What mixed content warnings actually mean

When a page loads over HTTPS, everything on it should also arrive over HTTPS: images, stylesheets, scripts, fonts, videos and embedded frames. If even one of those files is requested with an old HTTP address, the page is said to contain mixed content.

Browsers treat this in two ways:

  • Passive mixed content includes images, audio and video. Modern versions of Chrome, Firefox and Safari try to upgrade these to HTTPS automatically. If the upgrade fails, the item simply does not load, and you may see a broken image.
  • Active mixed content includes scripts, stylesheets and iframes. Browsers block these completely, because an attacker on the same network could alter them and take over the page. This is why a site can suddenly lose its styling or its contact form after the switch.

Either way, visitors see a weaker security indicator, and some will leave. It also undoes part of the trust benefit you got from installing a certificate in the first place.

How to find mixed content on your pages

You do not need any paid tool for this. Your browser already tells you exactly what is wrong.

  1. Open the page in Chrome, Edge or Firefox.
  2. Press F12, or right click and choose Inspect, to open the developer tools.
  3. Click the Console tab and reload the page.
  4. Look for yellow or red messages that start with "Mixed Content." Each one names the page and the exact file that was requested over HTTP.

Write down every file listed. Then repeat on your other key templates: the home page, a blog post, a category page, the contact page and any page with a form or embedded video. Mixed content usually comes from a handful of sources that repeat across many pages, so the list rarely gets long.

For a larger site, a crawler such as Screaming Frog, which is free for up to 500 addresses, can scan every page and report insecure resources in one go. It is the same approach used when you find and fix broken links on your website.

How to fix mixed content warnings, source by source

In my experience, mixed content on a small site comes from one of five places. Work through them in this order.

1. Hard coded addresses in posts and pages

Older content often has images inserted with the full HTTP address of your own domain. On WordPress, the cleanest fix is a database search and replace. If your host gives you WP-CLI, the search-replace command swaps every old HTTP version of your domain for the HTTPS version in one pass. Run it in dry run mode first to see how many rows will change, and take a backup before the real run. If you do not have command line access, a plugin such as Better Search Replace does the same job through the dashboard.

2. The site address setting

In WordPress, go to Settings, then General, and check both the WordPress Address and the Site Address. They must start with HTTPS. Other platforms have a similar base address setting, usually under general or domain settings.

3. Your theme and its files

Some older themes load fonts, icons or scripts from hard coded HTTP addresses inside their template files. Search the theme folder for the plain HTTP prefix. Change those to HTTPS, or better, to relative paths that start with a slash. If the theme is no longer maintained, that is a strong sign it is time to replace it.

4. Third party embeds

Old video embeds, booking widgets, maps and analytics snippets may still use HTTP. Go back to the provider, generate a fresh embed code, and paste it in. Almost every reputable service has supported HTTPS for years. If one does not, remove it.

5. Stylesheets with background images

Custom CSS added through the theme customiser often contains background image addresses. Open it and look for any line that still uses HTTP.

Why I avoid the plugin shortcut

The most common advice for WordPress users is to install a plugin that rewrites HTTP to HTTPS on the fly every time a page loads. It works, and the warning disappears in seconds. I still recommend against relying on it.

The problem is that the insecure addresses are still in your database. The plugin is rewriting them on every single page view, which adds a little processing time. If the plugin is ever deactivated, updated badly or removed during a theme change, every warning comes straight back, sometimes months later when nobody remembers why. It also does nothing for content you export, move to another platform or send through an RSS feed.

Use the plugin, if you like, as a temporary bridge for a day or two. Then fix the source with a proper search and replace, and remove the plugin. The same principle applies to most maintenance work, as covered in our guide to keeping your website secure and up to date: fix the cause, not the symptom.

Lock it in once everything is clean

After the console shows no mixed content warnings on your main templates, add two safeguards so the problem does not creep back.

  • Force HTTPS redirects. Make sure every HTTP request to your domain gets a 301 redirect to the HTTPS version. Most hosts have a single toggle for this.
  • Add an upgrade header. A Content Security Policy header with the upgrade-insecure-requests directive tells browsers to request any stray HTTP resource over HTTPS automatically. It is a safety net, not a substitute for clean content.

Finally, take a fresh backup now that everything is clean, and keep it separate from older ones. If you have not yet tested a restore, our step by step guide on backing up your website and testing the restore is worth an hour of your time.

Frequently asked questions

Why does my site say not secure even though I have SSL?

The most common reason is mixed content: some images, scripts or styles are still loaded over HTTP. Open your browser console to see the exact files. Other causes include an expired certificate or a certificate that does not cover the www version of your domain.

Does mixed content affect SEO?

Not directly as a ranking penalty, but it can still hurt. Blocked scripts or styles can break your layout, slow pages down and make visitors leave, all of which affect how search engines see your site. A clean HTTPS setup is part of basic technical SEO.

How do I fix mixed content in WordPress without a plugin?

Update the WordPress Address and Site Address to HTTPS, then run a database search and replace from the old HTTP domain to the new HTTPS one, using WP-CLI or your host's tools. Check your theme files and custom CSS for hard coded HTTP addresses. Finally, refresh any old embed codes.

AH
Astrid Holm

Astrid writes about designing and looking after websites, focused on clarity, usability, and sensible upkeep.

More posts by Astrid

More in Maintenance and Security

01doorganico 084goad 3hot8 4465456 after5internprogram ahandfulofblessings ahmadpc ahomcybersecurity allodialresources annodex antiquesandperiodcollectibles aotc asianworldkashmir beedlectrics bloggertemplatefree bluefeatheragency bodyweightsolution campaign08blog carfixadvisor catstreetcollective cbstvsports cnfanspurchasing committeeof500yearsofdignityandresistance covertopsdjs cs-kaiyuangame cuestacomunicaciontotal cxoutlet dancebetgame deskgearhub destinyvillastay detectmagazine di33 diamondsteelbuildings donmo dyanadropship emarsysfinance emimattl escapechan eskitarih evautoplay everythingweddings-orlando farmzone feedviewerapp foxstudiosscratch gamevui123 gleasongrade greetingsday hacklabasu haskell iw-kaiyun jagoanproperti jilidskripsi joltbusinessfinance juegodepokergratis juegospucca kaeru-festival latestmehndidesigns lestanzediottaviano litemagazines localcommunityhero lustrsazan mariashebets menswheels nikkit ootheday oxigenvpn plurfitness prefetial probudgetcarpetcleaning psychicmrsmartin pyaten qvantor rejoignezlogis rexzbot riselayouts ruchin rwxqsgd5 sakaltime shibiaowang shop-bot skrtips spotlesshaven strcoding tetapatrium topselller uneplanteartificielle vipertechcr webtech1223411 wo-kygaming yamaha-mekar yeknava yoybuysheets zenunwa yamaha-mekar jilidskripsi ankertoto ankertoto ankertoto