Usually shared hosting panels have simple parking, forwarding tools. But when it is about cloud/dedicated servers – most things should be done manually or throught DNS manager.
For example, if you want to forward example1.com to example2.com, you can create example1.com website in your server, and then you can forward it to example2.com by using webserver redirect command or just with code (php, javascript, python etc.)
But it is not good way just because needs creating some unneeded codes, instances.
Cloudflare rules allow you to create beautiful smart rules for your web traffix. One of them is forwarder.
Once you added your new domain to Cloudflare, choose that domain, just open PAGE RULES tab and do the steps below:
- Click to “create page rule button” and enter your domain name with /* endfix
- Click to Add a Setting link, and choose Forwarding URL option.
- Check 301 option as a redirect status. (or 302, if you aware what it is)
- Click to Save And Deploy button.
That’s all. Now you have got simple rule for forwarding – without doing any coding.