Migrating a website to a new domain, whether for rebranding, expansion, or simply securing the ideal .com, is a significant step.
Done right, you’ll protect your SEO value, retain backlinks, and ensure a smooth user experience. This updated guide will show you how to migrate ANY domain to ANY OTHER domain, using Cloudflare for painless redirects and WordPress for your content.
What is Cloudflare? (And Why Is It Free and Worth Using?)
Cloudflare is a globally recognised platform that acts as a performance and security layer between your website and visitors. It works as a reverse proxy, routing all your web traffic through its global network of data centres. This brings several significant benefits:
- Faster Load Times: Cloudflare utilises a worldwide content delivery network (CDN) to cache and serve your website content from locations closer to your visitors, resulting in a noticeably quicker site.
- Free SSL Certificate: Automatic, no-cost HTTPS/SSL encryption helps secure your site, boosts user trust, and improves SEO.
- Powerful Security: Cloudflare’s free plan protects your site from threats like DDoS attacks, malicious bots, and abusive traffic.
- Reliable DNS Management: Their intuitive, fast DNS lets you manage domain records through an easy GUI.
- Simplicity and Cost: Cloudflare offers a generous free plan that covers most small businesses and personal sites. No credit card or payment is needed setup is free and only takes minutes.
Setting up Cloudflare means your site is safer, faster, and easier to manage at zero cost.
Step 1: Add Both Domains to Cloudflare
Before you touch your web host or WordPress, add both your old and new domains to your Cloudflare account:
- Go to Cloudflare dashboard and add both the current (old) domain and the new domain.
- Make sure both domains are “active” in Cloudflare (they should be proxied, with the orange cloud enabled).
Step 2: Prepare Your New Domain in cPanel (or Your Hosting Dashboard)
- Log in to your web hosting control panel (e.g., cPanel).
- Add the new domain to your hosting account.
- Double-check that the new domain points to the correct folder/directory where your WordPress site files will live.
- When finished, copy the IP address of your hosting account.
- Return to Cloudflare and update the DNS settings for your new domain to point any relevant A records to your hosting server’s IP address.
Step 3: Prepare and Launch Your New WordPress Site
If your site is already on the new domain, or you’re starting with a fresh WordPress site, you can proceed. No need to reference copying or migration; these instructions apply whether your new WordPress install is brand new or existing.
Just ensure your content, plugins, and settings are ready.
- In the WordPress dashboard (Settings > General), set the WordPress Address (URL) and Site Address (URL) to your new domain.
- Use a plugin like Better Search Replace to update all internal links and media URLs in your database to the new domain.
- Ensure SSL (HTTPS) is active for your new domain (via cPanel or Cloudflare).
- Test your new domain by visiting it in a browser and confirming that it loads securely and correctly.
Step 4: Set Up 301 Redirects in Cloudflare
- Go to Cloudflare’s dashboard for your OLD domain.
- Use Page Rules or Redirect Rules to match all URLs (e.g.,
*olddomain.com/*) and send a 301 Permanent Redirect to the new domain (e.g.,https://newdomain.com/$1), which preserves the path.- Make sure DNS (A) records exist for the old domain and are proxied via Cloudflare.
- Redirects for changed URLs on the new site:
If some old URLs correspond to new URLs (for example,/old-pagenow lives at/new-page), keep following these Cloudflare instructions for domain-wide forwarding, but then set up post-redirects in your new WordPress site. Use a WordPress plugin (like Redirection) to map/old-page(on the new domain) to/new-page. This way:- olddomain.com/old-page → (Cloudflare 301) → newdomain.com/old-page → (WordPress 301) → newdomain.com/new-page
This ensures every incoming link is correctly routed.
- olddomain.com/old-page → (Cloudflare 301) → newdomain.com/old-page → (WordPress 301) → newdomain.com/new-page
Step 5: Notifying Google via Google Search Console (GSC)
Migrating? You must let Google know! Here's how:
- Add both your old and new domains to Google Search Console (GSC):
- Log into Google Search Console.
- Verify ownership of both domains (old AND new).
- Submit a sitemap for your new domain (in the GSC property for your new domain).
- Use the ‘Change of Address’ tool:
- Sign in to GSC, select the OLD domain property.
- Go to Settings > Change of Address.
- Follow instructions to specify your new domain.
- Google will verify ownership, check redirects, and process the domain change request.
- Monitor both properties in GSC for indexing and errors during the transition.
Step 6: Post-Migration Checklist
- Check for and fix any hardcoded links or references to the old domain in your content or theme.
- Notify important linking partners, customers, or stakeholders about your new domain.
- Monitor Google Analytics and GSC for traffic and crawl errors.
- Let Cloudflare handle the old domain’s redirects for at least 6–12 months (longer is better!).
Resources: Learn More About Domain Migrations
- Google Search Central – Site Moves with URL Changes
- Cloudflare Docs – Creating URL forwarding rules
- WordPress.org – Best Search Replace plugin
- WPBeginner Guide – How to Move WordPress to a New Domain
- Ahrefs Blog – Complete Guide to Website Migration
Want AI-Guided Website Migration Coaching?
If you'd like real-time, personalised help, click a link below. Each AI will ask you questions and guide you through the process.
The following prompts will reference this article directly.
Migrating your domain is a big move, but with careful planning (and a bit of Cloudflare magic), you’ll be live on your new address with no SEO hiccups. Good luck!