×
UpdatePHP Pro Log in Register
PHP expiry alert : PHP v8.1 has recently expired. Is your website still running this version? Click here for more details
SAFE versions of PHP: 8.5.12, 8.4.27, 8.3.36, 8.2.35
☰

Moving your PHP website to a new host without losing Google rankings

If your current host can't offer a supported PHP version, moving to a new one is often the best fix. The good news is that changing host on its own doesn't harm your rankings: Google ranks pages by their address and content, not by which server they live on. Rankings drop when something changes by accident during the move, such as addresses, content, or the site being unreachable for a while.

The safest approach is to change as little as possible at once. Move the site as it is, check everything, and leave redesigns or new URLs for later.

Before the move

  1. Record where you stand. Export your top pages and search queries from Google Search Console, and make a list of all your URLs (from your XML sitemap or a site crawler). You will use this list to check the new site.
  2. Take a full backup of files and database, and keep it until the move is long finished.
  3. Lower your DNS TTL (time to live) to around 5 minutes a day or two in advance, so the switch to the new server spreads quickly.
  4. Set up the new server with your target PHP version, and make sure PHP extensions, upload limits and memory limits match what the site needs.

Test the copy before going live

Most hosts give you a temporary address, or you can preview the new server by editing your computer's hosts file. Go through your key pages, forms, logins and checkout on the new server before changing DNS. Our guide to testing your website on a newer version of PHP covers this in detail.

Make sure search engines can't index the temporary copy (password protect it or add a noindex tag), and just as importantly, remove that protection when the site goes live. A forgotten noindex tag or a Disallow: / line left in robots.txt is one of the most common causes of a site vanishing from Google after a move.

On moving day

  • Keep every URL exactly the same, including the domain, www or not, HTTPS and trailing slashes.
  • If any URLs must change, add a 301 redirect from each old address to its new one. Avoid sending everything to the home page.
  • Put the old site into read-only mode, or pause new orders and comments, so nothing is lost while DNS changes over.
  • Keep the old hosting running for at least a week. Some visitors and crawlers will still reach the old server until DNS has fully updated.

After the move

  • Check that the site loads over HTTPS with a valid certificate on the new server.
  • Crawl your URL list and confirm every page returns 200 (or the intended 301).
  • Check robots.txt, noindex tags and canonical tags.
  • Resubmit your XML sitemap in Search Console and watch the Pages and Crawl stats reports for errors over the next few weeks.
  • Compare page speed with before. A modern PHP version on a better server should be faster.

Google's Change of Address tool is only for moving to a new domain name. If you are only changing host, you don't need it.

Planning the move

Read about choosing a host that uses up-to-date PHP, the upgrade steps for migrating a PHP website and how to back up your website. If you'd rather have an expert do it, find a PHP developer.

Back to Web SEO & Security Articles
Article last updated: 21st October, 2026