Skip to content
FunnelGuard

Fix guide by FunnelsGuard

HTTP not redirected to HTTPS: how to find and fix it

OPS-064High impactDetectedBy FunnelGuardPublished Updated
On this page

What this issue is

HTTPS is the encrypted version of a web address. Even when you have a valid certificate, the old http:// address can still respond. If it serves the page with a 200 status instead of sending a redirect, the issue is present: http is not redirected to https.

It often shows up after a migration, when a certificate was installed but the redirect rule was never added. It can also hit only some URLs, for example the www version, a landing page on a subdomain, or paths handled by a different server.

What happens to a visitor on an http link
  1. Click old http linkAd, email or bookmark uses http://
  2. Server answers 200No 301 to https is sent
  3. Browser shows Not secureForm and checkout pages load unencrypted
  4. Lead or saleVisitor leaves or data is exposed

The http request is never upgraded, so everything after it happens on an insecure page.

Why it costs you leads or sales

Browsers label http pages as not secure, and many visitors will not fill in a form or enter payment details on them. Some browsers also block or warn about forms submitted from insecure pages.

There are other costs. Search engines can index both versions and split your ranking signals. Analytics can record the same page under two addresses, and ad landing pages on http may behave differently from the https page you tested. Data sent over http can be read or changed on the network.

Traffic split across two versionsExample numbers
Traffic split across two versions (example)Served on https: 70 % of sessions; Served on http: 30 % of sessions027547030Served on httpsServed on http% of sessions

Example: without a redirect, some sessions land on the insecure http version. Numbers are illustrative only.

How to check if your site has it

Request the http version without following redirects and read the status code. You want a 301 (or 308) and a Location header pointing at https.

Check the http responsebash
curl -I http://example.com/
curl -I http://www.example.com/
curl -I http://example.com/pricing?utm_source=test

# Good:
# HTTP/1.1 301 Moved Permanently
# Location: https://example.com/
# Bad:
# HTTP/1.1 200 OK
Test every variant
  • http://example.com (apex)
  • http://www.example.com
  • A deep page, not just the home page
  • A URL with query parameters such as utm_source or gclid
  • Every subdomain used for landing pages, booking or checkout

How to fix it

First confirm the https version works and has a valid certificate. Then add one permanent redirect rule in one place. Pick the layer that actually receives the request first: the CDN, the platform setting, or the web server.

Force https on your platform
  1. Set https addresses

    In Settings > General, change WordPress Address and Site Address to start with https://.

  2. Add a server redirect

    On Apache, add the rewrite rule from the Custom code tab to .htaccess above the WordPress block. Many hosts also offer a Force HTTPS toggle in their control panel.

  3. Fix leftover http links

    Update hard-coded http URLs in content and theme settings, using your preferred search-and-replace tool.

Apache: redirect all http to httpshtaccess
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L]
Nginx: redirect port 80 to httpsnginx
server {
    listen 80;
    listen [::]:80;
    server_name example.com www.example.com;
    return 301 https://$host$request_uri;
}
Request to http://example.com/pricing

Before

  • Server returns 200 on http
  • Browser shows Not secure
  • Search engines can index two versions

After

  • Server returns 301 to https://example.com/pricing
  • Visitor lands on the secure page
  • One canonical version to index and track

How to confirm it's fixed

Verify the redirect
  1. Run curl on each variant

    Check apex, www, a deep page and a URL with query parameters. Each should return 301 with a Location on https.

  2. Follow the chain

    Run curl -IL and confirm the final response is 200 on https with no more than one or two hops.

  3. Check parameters survive

    Confirm utm_source and gclid are still in the final URL.

  4. Test a form

    Load the http address of a page with a form, submit it and confirm it works on https.

How to prevent it happening again

Keep https enforced
  • Add the redirect check to your migration and launch checklist
  • Re-test after changing hosts, CDN, DNS or domain settings
  • Set canonical tags and sitemap URLs to https
  • Use https in all ad URLs, email links and social profiles
  • Add an HSTS header once everything works on https (see OPS-062)
  • Run a scheduled check so a change is caught in hours, not weeks

How FunnelGuard handles this

FunnelGuard detects this issue today. Its redirects check requests the http version of your pages and tests whether it is sent on to https. If the http address is served directly instead of redirecting, you get one alert, after the failure is re-checked from a second region, with a screenshot and a likely cause.

Checks run on a schedule as a robot visitor, with test traffic marked by utm_source=funnelguard and fg_test=1. The Free plan covers 1 site and 2 journeys with daily checks and no card. Paid plans start with a 3-day free trial, and a free read-only website audit is available too.

Redirects interact with other HTTPS settings. After this fix, review HSTS, redirect loops and any forms that still post to http.

Questions people ask

Why is my site still loading on http instead of https?

The http address is answering with a normal page instead of a redirect. A certificate only enables https; it does not force it. You need a 301 redirect rule at the server, CDN or platform level.

How do I redirect http to https?

Add a permanent 301 redirect from http to the same path on https. On Apache use a RewriteRule in .htaccess, on Nginx use return 301 https://$host$request_uri, and on hosted builders switch on the force-https or SSL option.

Should I use a 301 or 302 redirect for https?

Use a 301 (or 308), which is permanent. It tells browsers and search engines the https address is the real one. A 302 is temporary and can leave the http version in search results.

Does an http to https redirect hurt tracking or UTM parameters?

Not if the redirect keeps the path and query string. A rule that drops the query string loses utm_source, gclid and similar values, so test a URL with parameters after you set it up.

How can I test if http redirects to https?

Run curl -I http://yourdomain.com and check for a 301 status with a Location header starting with https://. Test the www version and a deep page too, and use a private window to avoid browser caching.

Why do I get a redirect loop after forcing https?

This often happens when a CDN handles https but connects to your server over http, and your server then redirects again. Set the CDN to connect to the origin over https, or make the server aware of the forwarded protocol.

Is HSTS the same as an https redirect?

No. The redirect sends the first http request to https. HSTS is a header that tells the browser to use https by itself on later visits. You need the redirect first, and HSTS is an extra layer.

Can FunnelGuard tell me if http is not redirecting to https?

Yes. Its redirects check tests whether the http version of your pages is sent to https and alerts you if it is not. It re-checks from a second region first and includes a screenshot and a likely cause.

Does FunnelGuard catch this?

Detected

FunnelGuard checks for this today.

How: redirects matcher.

Stop finding out from your customers

FunnelGuard runs your real forms and checkouts on a schedule, checks the tracking and the leads behind them, and alerts you once, with a screenshot. Try any paid plan free for 3 days.