How to redirect old domain urls to new dowmain urls permanently

I just bought a new tld extension of my domain, let’s say it is domainAB.co. It has hundreds of URLs. My old domain is domainAB.com.

I want to redirect all of the URLs to the new TLD domain, for example:

domainAB.com to domainAB.co
domainAB.com/home1.php to domainAB.co/home1.php
domainAB.com/home1/123.php to domainAB.co/home1/123.php

Basically if a user visits any kind of old url he/she redirects to the new one.

Without Cloudflare i can easily do this via Apache with :

RewriteEngine on
RewriteRule ^(.*)$ https://www.domainAB.co//$1 [R=301,L]

  1. If I do the apache redirect and both my domains are on Cloudflare, the domain is redirected like:

domainAB.co/// and does not open

  1. If do it without apache and using Page rules, I can only redirect the home page

Is there anyone who can help me here?

I’ve tried everything I can.

#Tutorials has a dedicated article on that.

Could you please link the article?

Post a screenshot of your page rule then.

My page rule is:

domainAB.com/

to

https://domainAB.co/$2

A screenshot.

I cannot share the screenshot, apologies.

Why?


I cannot disclose my domain name, simple as that mate.

What one needs is the rule and I’ve mentioned that already.

If you can’t share the domain the community cannot help you.

All I can say is double check that you followed the tutorial, then it will work.

Then please don’t. I care about the privacy here. If anyone wants to help he/she would just share the details here rather than asking for the screenshot.

What If I never created the Page Rule and simple asked for the help?

Nonetheless thanks for your time and support.

Look, if you need help you need to assist and provide as many details as you can. If you don’t want that you are on your own I am afraid. You were already provided with the applicable tutorial.

If you never created the page rule it certainly cannot work in the first place. As I already said, double check that and it will work, that’s all that is to be said about that.

If you don’t want to share the domain publicly, all I can offer is that you run a check with the domain at sitemeer.com and post here the exact time when you ran it, then I can dig it out.

Otherwise opening a support ticket is your only option.

Ehm, you edited your response. You said originally you already followed that article.

I edited to make sure that I followed the correct article.

I will open a ticket then.

Fair enough, but I’d really follow the tutorial as that has been used by thousands and will work. Simply double check it.