Https -> http loop for custom domain in Cloudflare Page

For Workers & Pages, what is the name of the domain?

dev.finchleyhs.org

What is the issue or error you’re encountering

Getting a 301 redirect to https and then back to http

What steps have you taken to resolve the issue?

Checked DNS entires and SSL setup

What are the steps to reproduce the issue?

Happens in Safari and Chrome, no matter the cache. Also happens in curl (Cloudflare community is preventing me from posting the full output of curl as it takes them as “links”):

curl -I
HTTP/2 301
date: Wed, 05 Mar 2025 14:19:55 GMT
content-type: text/html
content-length: 167
location:

curl -I
HTTP/1.1 301 Moved Permanently
Date: Wed, 05 Mar 2025 14:20:16 GMT
Content-Type: text/html
Connection: keep-alive
Cache-Control: max-age=3600
Expires: Wed, 05 Mar 2025 15:20:16 GMT
Location:

Somehow it does occasionally load and quit with the redirect in my browser.

My post didn’t seem to format properly. With the curl outputs, it basically flip flops between https://dev.finchleyhs.org/blog/ and Eleventy Base Blog v9

Please check if you have any Page Rules, Redirect Rules or Bulk Redirects on Cloudflare.

1 Like

Thanks for response.

I don’t have any page rules at all (says I’ve used 0 out of 3)

Not sure where redirect rules would be, but from documentation it would seem to be the same place?

Looking up “bulk redirects”, that would have to be a worker if I understand correctly? I don’t have any workers.

I just tried putting “https://dev.finchleyhs.org” into https://httpstatus.io - if I keep submitting, you get a random number of redirects.

Can you use the Trace tool to check where the redirect is coming from? https://dash.cloudflare.com/?to=/:account/trace

No, Bulk Redirects aren’t related to Workers.

Not the same, but close:

1 Like

That screenshot shows your email address, so you might want to remove that if you can.

You also can’t find anything in Redirect Rules/Bulk Redirects? It’s weird, because the redirect is coming from within Cloudflare.

1 Like

I see no redirect rules:

And just to make 100% sure, you also don’t see any Bulk Redirects? I highlighted where you find them in my previous screenshot.

1 Like

Thanks for your help.

The list of rules and the bulk button disappears after the page fully loads - I was only just able to capture a screenshot of it before the “Create Rule” button appears, and a bunch of templates.

I’m assuming if I had one, it would show me the button?

That’s weird. You can also find Bulk Redirects if you go back in the top left corner. You can then find Bulk Redirects at the bottom of the menu.

I think potentially it’s something to do with this ERR_TOO_MANY_REDIRECTS · Cloudflare SSL/TLS docs

However, I can’t currently try “strict”, as that would apply to the currently live site (and I think that will mess it up)

No, if it was due to the SSL mode, the redirect would be from your origin, not from Cloudflare.

But you should always use Full (Strict) anyway, the other modes are insecure. With configuration rules, you can also change the setting per hostname instead of globally.

1 Like

Yes I would use strict if I could - at the moment we have a legacy Wordpress, and the last time I tried it, the rewriting for the static content to https failed, and completely broke things. I’m thus trying 11ty on the dev.finchleyhs.org custom domain first.

The documentation for Pages seems a bit unclear - does Cloudflare itself consider Cloudflare Pages to be an “origin”, albeit an implicit one?

Yes, Cloudflare Pages would be an Origin. I forgot you mentioned Pages at the beginning.

If you don’t have any Page Rules/Redirect Rules/Bulk Redirects, you probably have a redirect configured in your Pages project.

1 Like

I don’t see anything to do with redirects in the Pages section. I don’t have any “integrations” or “redirects” files in the deployment.

So I’m at a bit of a loss as to what’s happening.

Do you also get these redirects if you use the .pages.dev subdomain?

1 Like

No it works absolutely fine with the default pages.dev subdomain.

Could it be something to do with the fact that my root/naked domain is pointed unproved to my Wordpress server, and ‘dev’ subdomain is a proxied CNAME to Cloudflare Pages?

Is there some incompatibility with having both of those things?

At the moment the SSL mode is “automatic - off”, so does that mean it thinks it’s talking to the Cloudflare Pages “origin” with http, and causing an issue there?

As I say, I’m a bit limited testing on this domain as I don’t want to mess up the current site until I’ve got things working on the subdomain.

unproved → unproxied (I can’t edit posts :frowning: )

Oh well, that explains things. Change it to Full (strict), it does not affect your unproxied site.