Storytime, ready? One of our clients had some legal troubles with its brand name in the EU. They needed help transitioning to a new brand name, which would involve a change of website address (domain). Still, they didn’t want to lose the SEO value they had generated with their previous domain name… which was possible in the transition. They asked us to help them with this transition from a site- and SEO-perspective - specifically, the main items they needed to address to maintain that value.
They wanted to know:
- How to preserve an existing "SEO Juice" from the brand name after the site migration?
- How to approach redirects?
- How to preserve (if possible) any of the digital outreach we did for the brand?
- Anything else that they need to know from an SEO standpoint
The following is our take on how we recommend best approaching this kind of domain name switch from an SEO perspective.
For this article, let’s assume your site’s domain is oldsite.com, and you will be changing it to newsite.com.
There are two possible case scenarios:
- Site move without changes to URLs
- Site move with changes to URLs
The best-case scenario is when only the domain name changes and the site's structure remains the same:
If that's the case, you’re lucky; the development team would only have to add one redirect rule within the site's HTACCESS file.
Let's say you want to change the domain name of your WordPress site that runs on Apache. You can add the following lines to your .htaccess file located at the root of your oldsite.com domain:
That redirect rule would 301-redirect a request for any page of oldsite.com to the same page of newsite.com. Google says it is the best way to preserve SEO juice - keep the same structure if possible.
If there were changes in the site's structure, we would create a 301-redirect plan (mapping old and new URLs):
Ideally, the client's team would need to map old URLs to new URLs. I suggest including URLs of these pages into a redirect plan:
- Top URLs by pageviews from the All Pages report of Google Analytics (Behavior > Site Content > All Pages)
- Top organic landing pages by sessions in the last three months (in Google Analytics, go to Behavior > Landing Pages, select Medium as the second dimension, and add a filter "medium exactly matching organic")
- URLs of pages with inbound links (here, you want to use as many backlink tools as possible: Search Console of all verified versions of the site, SEMRush, Moz, Google Analytics full referrals, etc.)
The following lines of the HTACCESS would 301-redirect our sample pages to their new locations:
Hosted e-commerce solutions such as Shopify don't give you access to HTACCESS. You would first need to add your custom domains to Shopify and then redirect them to your primary domain.
CAUTION: If you have any Shopify apps that depend on these domains not redirecting to your primary domain, speak to the app developer before making this change.Redirect a domain for the Shopify plan or higher From your Shopify admin, go to Online store > Domains. Click Manage next to the domain that you want to redirect. Select Redirect to Primary domain. Redirect a domain for the Basic Shopify plan From your Shopify admin, go to Online store > Domains. In the Primary domain section, click Enable redirections. Click Enable redirections again.
More on Shopify site migration: What you need to consider when migrating
Here is the process to follow:
- Create two valid XML sitemap files: one containing URLs of the old site and the other URLs of the new site. Reference them both in oldsite.com/robots.txt using Sitemap declaration for auto-detection (Google is not the only search engine, and search engines use robots.txt to discover XML sitemaps). Once redirects are implemented (see Step 3), we will need to submit these two XML sitemaps via Google's Search Console of verified oldsite.com. Note: on Shopify and some other SaaS e-commerce platforms, you cannot create custom sitemaps. It might not always be possible to generate an XML sitemap containing URLs of the new domain.
- Verify both oldsite.com and newsite.com in Google Search Console. We will need this in Step 4.
- Implement 301-redirects. Again, the implementation will depend on what is being changed, just the root domain or the root domain and site structure.
- Notify Google of domain name change using its Change of Address Tool.
- Using oldsite.com's Search Console Sitemaps tool, submit two XML sitemaps created in Step 1.
- Update all internal links of the new site. Find all links that point to pages of the oldsite.com and update them to point to their respective newsite.com pages (use Screaming Frog or similar software to crawl through pages of the new domain). It will be easy to identify the link’s new location thanks to 301-redirects implemented in Step 3.
- Update social profile accounts to make them point to a new domain.
- Reach out to webmasters of domains that point to oldsite.com, and ask them to update their links (if you really want to be thorough). Links now need to point to pages of newsite.com. Ideally, the branded anchor texts of those links will also need to include a new company name. Google suggests that we concentrate on links that drive the most referral traffic to our site.
- Monitor traffic. In step 5, we submitted two sitemaps. Each sitemap lists the number of pages submitted and how many of these submitted pages are in Google's index. Over time, the number of indexed pages of oldsite.com will decrease, and that of newsite.com increase. We can also use the All Pages report in Google Analytics to see pages that are triggering 404 and fix them as they appear.
A couple of extra things to keep in mind:
- Keep the old domain active for as long as possible (at least three months or more). Google says the time it takes for them to crawl your website and update their indexes (and pass link juice) depends on multiple factors. Among them, how many pages there are, how fast the server response time, how authoritative the website is (that is, its inbound link profile), etc.
- Don’t create redirect chains. It is okay for page A to redirect to page B. Page A that redirects to page B that then redirects to page C causes a redirect chain, leading to the lost link juice.
And that’s all you have to know about a domain name change - at least that’s how we handle it at Sb when a website is moved. This procedure can be very tricky, and before you make any decisions, consult with your development department or reach out to us for help. You’ve put years into your SEO, don’t lose it all by being hasty!