Flash Sale:75% Off Hosting + Free DomainEnds in13h47m14sView Plans
Hostvento logoHostvento

How to Redirect One Domain to Another Domain

This guide shows you how to send visitors from one domain name to a different one. For example, old-name.com can lead to new-name.com.

Domains and DNS2 min read11 steps

What is a redirect?

A redirect is like a sign on a shop door that says "We moved. Go to the new address." The visitor types the old domain. The browser then goes to the new one.

A permanent redirect (code 301) tells search engines that the move is for good. A temporary redirect (code 302) says the move is only for a while. Use permanent when you moved for good.

Before you start

  • The old domain must point to your hosting. Check its nameservers or A record.
  • The old domain must be added to your hosting account, for example as a domain in cPanel.
  • Changing redirects affects a live site. Note down your current settings first.

Method 1: cPanel Redirects

  1. Log in to cPanel. Your welcome email shows how.
  2. Find the Domains section and click Redirects. In older versions it is on the main page.
  3. Next to Type, choose Permanent (301).
  4. Pick the old domain from the list under https?://(www.)?.
  5. In the box after the slash, leave it empty to redirect the whole site.
  6. In Redirects to, type the full new address, for example https://new-name.com.
  7. Choose Redirect with or without www so both forms are covered.
  8. Click Add.

Method 2: the .htaccess file

The .htaccess file is a small settings file in your site folder. Open it in File Manager. Back it up first. A typing error can make the site show an error.

RewriteEngine On
RewriteCond %{HTTP_HOST} ^(www\.)?old-name\.com$ [NC]
RewriteRule ^(.*)$ https://new-name.com/$1 [R=301,L]

This sends every page on old-name.com to the same page on new-name.com. Change the two names to yours.

Tip: Test in a private window. Browsers remember 301 redirects, so an old setting can seem to stay.

Check the result

  1. Type the old domain into your browser.
  2. Check that it lands on the new domain.
  3. Try an inner page too.

If it does not work, open a ticket at https://secure.hostvento.com/submitticket.php.

Quick recap

  • A redirect sends visitors from one address to another.
  • Use 301 for a permanent move.
  • In cPanel, use the Redirects tool.
  • Or add rules to .htaccess after a backup.
  • Test in a private window.