A 301 redirect sends visitors and search engines from an old page address to a new one, and keeps your search ranking. Use it when you rename a page or move to a new domain.
Option 1: cPanel Redirects
- Open cPanel and click Redirects in the Domains section.
- Set Type to Permanent (301).
- Choose the domain and enter the old path, for example old-page.
- Enter the full new address in Redirects to, then click Add.
Option 2: .htaccess
Add a line like this to the .htaccess file in your site's folder:
Redirect 301 /old-page/ https://yourdomain.sx/new-page/
To move a whole site to a new domain:
RewriteEngine On
RewriteCond %{HTTP_HOST} ^(www\.)?olddomain\.sx$ [NC]
RewriteRule ^(.*)$ https://newdomain.sx/$1 [L,R=301]
Download a copy of .htaccess before editing it. WordPress users can also use a redirect plugin.
Need help? Open a support ticket or email support@anykey.sx.