Redirect sub-domain URL to a different sub-domain URL using page rules doesn't seem to be working

I am migrating my website from A Blue Star{page name} to https://blog.abluestar.com/{page name}

I have both sub-domains passing thought the Cloudflare DNS

I have setup the following page rule

Matching: https://blog.abluestar.com/*/
Forwarding URL: https://blog.abluestar.com/$1

I would expect that the old URL would be redirected to the new URL. See example below.

Old URL: The Giant Claw Game! - Relay H-Bridge and Circuit Design - A Blue Star
New URL: The Giant Claw Game! - Relay H-Bridge and Circuit Design - A Blue Star

But instead I get the following error message ( ERR_NAME_NOT_RESOLVED) when I click the old URL link.

image

What have I done wrong?

Thank you for your time.

I also double check to see if the Cloudflare DNS was working from external sources and it appears to be. I used https://mxtoolbox.com/ for this check

www.abluestar.com

blog.abluestar.com

That must be a DNS resolution issue on your side.

Your www host works for me as well as on http://sitemeer.com/#https://www.abluestar.com/

I’d suggest to wait a bit more until your resolver flushes its tables and gets the updated records, after which it should work for you too.

Also, unless the first page rule really should be specific only to your blog host you could enabled HTTPS site-wide in the SSL/TLS settings and save that one page rule.

Thank you, this worked as you described.

You are correct, Eventually the page started producing a 404 error instead of a ERR_NAME_NOT_RESOLVED

Next problem:

I am hosting blog.ablustar.com on github pages and I have configured www.abluestar.com to be an alias of blog.abluestar.com. I incorrectly expected that the page rules would override the DNS alias.

The issue is that this request The Giant Claw Game! - Relay H-Bridge and Circuit Design - A Blue Star hits the github pages server and 404s because the domain www.abluestar.com does not exist there.

So there a way to “park” a domain with cloudfront. so that the “page rules” get a chance to run on the url?

This article says that the page rules should be running as long as the domain is proxied by Cloudflare in the DNS settings.

So why is the old url not redirecting to the new url ?

https://support.cloudflare.com/hc/en-us/articles/200172356-Why-isn-t-a-Page-Rule-working-

I figured it out. I needed two page rules to resolve both issues that I was having. See screen shot below.

Issue resolved

Thank you @sandro for your help

1 Like

This topic was automatically closed after 14 days. New replies are no longer allowed.