• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
NameHero® Blog

NameHero® Blog

Web Hosting Tips & Resources From NameHero

  • AI Agents
    • OpenClaw
    • Claude Code
    • n8n
    • Hermes Agent
    • Open WebUI
    • Docker
  • Hosting
    • Web Hosting
    • WordPress Hosting
    • WooCommerce Hosting
    • Enterprise Hosting
    • Email Hosting
    • HeroicGuard
    • GPU Hosting
    • Website Builder
  • VPS
    • Managed VPS
    • Unmanaged VPS
    • Flex VPS
  • Reseller
  • Gaming
  • Domains
  • Account
  • Blog Home
  • Categories
  • Authors

How To Correctly Redirect Your Domain (And Preserve Search Engine Rankings)

Ryan Gray

Published on: August 2, 2017

Categories: Web Hosting 0

Ever decide to pickup and move your website to a new domain?

What about buying a similar domain and needing to redirect it to your current website?

I’ve personally started two startups before using different TLDs than the .com.  Both names I wanted were registered and I didn’t want to fork out thousands of my startup budget until I at least had proven my minimum viable product (MVP) as successful.

Therefore once I was able to afford the .com, it was essential to pass my search engine rankings!

How To Redirect Preserving Search Engine Rankings

If you have already developed your website and are wanting to move everything to a new domain, you need to do a couple of things:

  1. Move your content
  2. Setup 301 redirects from the old website to new

Move Your Content

Moving your content shouldn’t be to hard.  If you’re using WordPress you can easily export all of your post data and re-import it into your new website.  You could also simply copy over the existing database as is and edit your wp options table to reflect the new domain.

To keep things simple, I also recommend retaining a similar URL structure on the new domain.

For example, if you were using https://old-domain.com/post-name-goes-here/ it would be easiest to keep https://new-domain.com/post-name-goes-here/.

While it’s still possible to change the URL structure, this will ensure you don’t run into any errors.

Setup 301 Redirects

A 301 redirect tells the search engines the content has been moved permanently allowing for your search engine rankings to pass through to the new domain. This also carries over your existing backlinks.

You can setup a 301 redirect by creating or modifying the .htaccess file in your root public_html directory.  You would want to format it like this:

RewriteEngine on
RewriteCond %{HTTP_HOST} ^old-domain.com [NC,OR] RewriteCond %{HTTP_HOST} ^www.old-domain.com [NC] RewriteRule ^(.*)$ http://new-domain.com/$1 [L,R=301,NC]

This would take into consideration that you have preserved the link structure to the old content.

How To Create And Manage Redirects In cPanel

The easiest way to do all of this is inside of cPanel.  This way, you don’t have to worry about modifying your .htaccess file, you can let cPanel handle it all.

I’ve recorded a brief video tutorial to show you how to do this:

As you can see, cPanel makes this so much easier than manually going in and editing your .htaccess file.  I personally like their “search” feature so you can quickly modify existing redirects.

If you have any questions or need our team to take a look to ensure you’re redirecting your website correctly, feel free to let us know!

Ryan Gray

Ryan Gray is the founder and CEO of NameHero, one of the fastest growing independent web hosts in the United States. Ryan has been working online since 1998 and has over two-decades experience in Internet Entrepreneurship.

Reader Interactions

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Primary Sidebar

Follow & Subscribe

Exclusive promos, content and more!


Most Popular Posts

NameHero’s Recommended WordPress Plugin and Theme Setup

WordPress Hosting vs. Web Hosting – What’s The Difference?

How To Increase The InnoDB Buffer Pool Size

How To Fix A Stuck All-in-One WP Migration Import

How To Add A Subdomain In Cloudflare

Top Categories

  • WordPress
  • WordPress Tutorials
  • OpenClaw Hosting
  • Enterprise Hosting
  • WooCommerce
  • Web Hosting
  • Resellers
  • Website Security
  • Website Development
  • Website Performance
  • VPS Hosting
  • SEO Tips
  • Announcements
  • Domain Registration
NameHero

NameHero® proudly provides web hosting to over 40,000 customers with 99.9% uptime to over 750,000 websites.

  • Master Card
  • Visa
  • American Express
  • Discover
  • Paypal
Products
  • Web Hosting
  • Managed VPS Hosting
  • Unmanaged VPS Hosting
  • Flex VPS Hosting
  • WordPress Hosting
  • WooCommerce Hosting
  • Reseller Hosting
  • Enterprise Hosting
  • GPU Hosting
  • Email Hosting
  • HeroicGuard
  • Domains
  • Website Builder
  • AI Agent Hosting
Help & Support
  • NameHero Blog
  • NameHero Gaming Blog
  • Support
  • Help Center
  • Migrations
  • Affiliates
  • Gaming Affiliates
  • Call 1-855-984-6263
Company
  • About Us
  • Contact Sales
  • Reviews
  • Uptime
  • We're Hiring

Copyright © 2026 Name Hero, LLC. All rights reserved.
NameHero® is a registered trademark.

  • Privacy Policy
  • Terms of Use
  • Acceptable Use Policy
  • Payment Policy
  • DMCA