.htaccess: Redirect old site to new one

When you move your website to a new domain, you may wanna redirect people to the new domain, so you don’t have to build your traffic all over again.

Add this to your .htaccess on your old website:

RewriteEngine on
RewriteCond %{REQUEST_URI} !http://brand-new-website.com/
RewriteRule $ http://brand-new-website/ [R=301,L]

Bookmark the permalink.

Leave a Reply

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

  • IGlr