Redirect from non-www to www not working

My page rule to forward from non-www urls to www urls doesn’t seem to be working. I’ve checked other community posts and the cloudflare guide, yet I don’t see anything I’ve done differently that wouldn’t cause it to work.

This is my page rule:*
Forwarding URL (Status Code: 301 - Permanent Redirect, Url:$1)

and my DNS configuration is attached as well.

Try using for your (www) A record.

That should work. It’s possible your domain is actually controlled by a third party Cloudflare SaaS partner. Who’s the host?

I use a VPS to host as of now whilst I test it.

Do you know if any of your Cloudflare settings are actually working?

For instance, a redirect for a URL like* (yes, foobar since it’s not a real path), and a 301 redirect to something like so if you go to the foobar directory on your server, you get redirected.

Or even a Firewall Rule: Hostname equals, then Block.


Creating this page rule:*
Forwarding URL (Status Code: 301 - Permanent Redirect, Url:

doesn’t forward the request at all, and I’m just greeted with my server’s 404 page.

Setting up the firewall rule also seems to have no effect whatsoever. Have I accidentally done something to prevent any of this from working?

The only setting that seems to be working is all my http requests are redirected to https. The thing is, when I disable Always Use HTTPS, the http->https redirections still happen anyway.

No. This is typical of Cloudflare SaaS partner hosting where you’ve left the service, but they haven’t release control over your domain.

Unfortunately the community is unable to assist you with issues such as this where an old provider used Cloudflare for SaaS. Please contact your old provider and ask them to remove any Cloudflare configurations for your domain, specifically SSL for SaaS / Custom Hostnames. If you contact Shopify and they mention Cloudflare headers, ask them if they are referring to a Custom Hostname that was part of an old SSL for SaaS implementation on the domain. Ask them to follow the process to create an HTTP ownership_verification record.

If you previously used HubSpot, please ignore this and move to the paragraph below.

If you are unsure who the previous provider is or they say they are unable to help you, please email [email protected] with the subject Cannot remove custom host name and details of the issue. Once you’ve done that you’ll receive an automatic response with a ticket number. Please post that here so we can escalate it. Once you have reached out to Support they will ask you to verify domain ownership of the domain by adding a txt record to the domain in order to verify domain ownership.

I purchased the domain and set up the cloudflare configuration only today, so I haven’t used any previous services. Are you sure this is still the issue? If so, I’ll do what is suggested. Thanks for your help!

All signs point to that. You’re the second person today with that issue. It’s either coincidence, or a bug.

This is my ticket number: 2324139

Ok, I’ve escalated that ticket. Someone should be on tomorrow morning to re-open it and check it out.

Thank you so much for your help!

1 Like

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.