Switching your WordPress site from HTTP to HTTPS is the best thing you can do for security, SEO, and user trust. But sometimes, after installing SSL, WordPress redirects incorrectly, causing issues such as:
-
Infinite redirect loops
-
Too many redirects error
-
Site stuck on HTTP
-
Site stuck on HTTPS
-
Some pages redirect, others don’t
-
Mixed content warnings
-
Images loading over HTTP
-
Wrong canonical URLs
-
Redirect chain errors
If your site is redirecting HTTP → HTTPS incorrectly, don’t worry — you’re not alone. This is one of the most common SSL-related WordPress issues.
In this guide, you’ll learn exactly how to fix every type of incorrect HTTPS redirect, including:
✔ .htaccess misconfigurations
✔ wp-config.php issues
✔ Cloudflare wrong SSL mode
✔ Reverse proxy issues
✔ Database URLs not updated
✔ Hosting-level HTTPS forcing
✔ Plugin conflicts
✔ Hard-coded HTTP links
✔ Mixed-content breaking redirects
This is the most complete and updated guide for 2025, and everything is copy-paste ready.
Why WordPress Redirects Wrongly After Enabling HTTPS
When you migrate to HTTPS, multiple layers control URL rewrites:
-
WordPress settings
-
Database URLs
-
.htaccess rules
-
wp-config constants
-
Server configuration
-
CDN (Cloudflare)
-
Reverse proxy (NGINX + Apache)
-
Plugins
-
Theme hard-coded URLs
If even one layer conflicts, the redirect becomes incorrect.
Example of common problems:
1. Infinite Redirect Loop
HTTP → HTTPS
HTTPS → HTTP
Repeats forever.
2. Too Many Redirects
Browser shows:ERR_TOO_MANY_REDIRECTS
3. HTTPS Works But Images Still Load Over HTTP
Mixed content blocks the secure version.
4. www vs non-www clash
http://www.example.com
https://example.com
Conflict happens → loop.
5. Cloudflare “Flexible SSL” Loop
Tells Cloudflare HTTPS but server still expects HTTP.
6. Reverse Proxy (e.g., Load Balancer) Incorrect Forwarding
WordPress sees HTTP even when HTTPS is being used.
Let’s fix all of this step-by-step.
1. Fix HTTPS Redirects in WordPress General Settings
Go to:
Settings → General
Ensure both fields match exactly:
WordPress Address (URL)https://yourdomain.com
Site Address (URL)https://yourdomain.com
Important:
No HTTP
No mismatched URLs
No mixed www and non-www
No trailing slash
If you can’t access the admin area, force them in wp-config.php:
Clear browser cache.
If redirect loop persists → continue below.
2. Fix .htaccess Redirect Rules (Most Common Issue)
Your .htaccess file may contain:
-
Duplicate redirect rules
-
Old plugin rules
-
Wrong HTTPS conditions
-
Conflicting redirect loops
Use the official recommended HTTPS redirect:
Now ensure the correct WordPress core rules exist below it:
Remove these if present:
-
Multiple redirect blocks
-
Redirecting to HTTP
-
Redirecting to www when your domain is non-www
-
Old plugin redirects
Fixing www vs non-www redirect conflict:
For non-www primary domain:
For www primary domain:
3. FIX: Cloudflare Incorrect HTTPS Redirect
If you use Cloudflare → MOST redirect loops happen because of Wrong SSL Mode.
Go to:
Cloudflare → SSL/TLS Settings → Overview
Set SSL to:
Full (best)
Full (Strict) (best if your host supports it)
Never use:
Flexible SSL → Causes redirect loops
Off → Causes HTTP/HTTPS mismatch
Strict if host lacks valid origin certificate
Also disable conflicting settings:
SSL/TLS → Edge Certificates → Always Use HTTPS → OFF
(If you’re already forcing HTTPS via .htaccess)
Rules → Page Rules → Remove ANY HTTP → HTTPS forcing
(It creates double redirects)
4. Fix Reverse Proxy / Load Balancer HTTPS Loop
If your site is behind:
-
Cloudflare
-
NGINX reverse proxy
-
AWS Load Balancer
-
LiteSpeed
-
HAProxy
-
Traefik
Your server may think visitor is using HTTP even when it’s HTTPS.
Add this to wp-config.php:
This alone fixes:
SSL loops
Mixed content
wp-admin redirect loops
Cloudflare Flexible mode behave weirdly
5. Fix Database URLs Still Using HTTP
If your database still contains:
http://yourdomain.com
Your site will partially redirect, causing:
-
Images over HTTP
-
CSS/JS over HTTP
-
Canonical tags incorrect
-
Internal links redirect wrong
Use WP-CLI (recommended):
Or use phpMyAdmin:
Run SQL query:
6. Fix Mixed Content Causing Redirect Errors
If some assets load over HTTP, browser may block HTTPS page, causing a broken redirect.
Search your theme for hard-coded HTTP URLs:
Fix by replacing:
Or make URLs dynamic:
7. Fix Plugin Conflicts Breaking Redirects
Common plugins that often break redirects:
-
Really Simple SSL
-
Redirection
-
Yoast SEO (if redirect set incorrectly)
-
WP Fastest Cache
-
LiteSpeed Cache
-
SiteGround Optimizer
-
WP Super Cache
-
W3 Total Cache
-
Hummingbird
-
Jetpack
Disable ALL plugins temporarily:
Rename the folder:
If redirect works → plugin conflict confirmed.
Re-enable plugins 1 by 1 until you find the culprit.
8. Fix Incorrect Hosting-Level Redirects
Some hosts force HTTPS automatically:
-
SiteGround
-
Hostinger
-
Bluehost
-
GoDaddy
-
Kinsta
-
WP Engine
Check:
Control Panel → Redirects or HTTPS Settings
Disable duplicate HTTPS forcing, especially if .htaccess already forces HTTPS.
9. Fix NGINX Users (No .htaccess)
If you use NGINX, add this redirect:
Reload server:
10. Fix “Too Many Redirects” Instantly (Emergency Quick Fix)
Add this to wp-config.php:
Clear cookies → Reload site.
This solves redirect loops in seconds.
11. Fix Incorrect Elementor, Divi or Page Builder URLs
Page builders store absolute URLs.
Regenerate CSS files:
Elementor
Elementor → Tools → Regenerate CSS & Data
Divi
Divi → Theme Options → Builder → Advanced → Static CSS File → Clear
WPBakery
Re-save page.
12. Reset All Redirects (Final Clean Approach)
-
Remove all redirects in .htaccess
-
Remove all Cloudflare redirects
-
Disable redirect plugins
-
Clear cache
-
Add only the official HTTPS rule
Your .htaccess should only contain:
Final Thoughts
Fixing incorrect WordPress HTTP → HTTPS redirects can be frustrating because the issue may come from multiple layers.
But once you follow this guide:
✔ Your redirects will work properly
✔ You’ll avoid loops and chains
✔ Your entire site will be secure
✔ Mixed content will be gone
✔ Search engines will index HTTPS only
✔ Website speed will improve
✔ SEO rankings will increase
FAQs
1. Why is WordPress stuck redirecting incorrectly after enabling HTTPS?
Because multiple redirect sources conflict, such as .htaccess rules, Cloudflare settings, database URLs, plugins, or hosting-level redirects.
2. How do I fix WordPress HTTPS redirect loops?
Correct your .htaccess, update wp-config HTTPS settings, ensure Cloudflare uses “Full SSL,” and check database URLs for HTTP.
3. Should I use plugins for HTTPS redirection?
No. It’s better to force HTTPS via .htaccess or server-level rules for speed and accuracy.
4. Why do images still load over HTTP even after SSL?
Because they are hard-coded in the database or theme. Run search-replace to fix old URLs.
5. Does Cloudflare cause redirect loops?
Yes — especially when using “Flexible SSL.” Use “Full” or “Full (Strict)” instead.