A redirect is a way to send both users and search engines to a different URL from the one they originally requested. The three most commonly used redirects are 301, 302, and Meta Refresh.
Getting Started with redirects
All redirects are done within your .htaccess file on your website. Note: This is a hidden file type so you might need to enable the view of hidden files on your server to see it.
301 redirect for SEO
This is a permanent redirect that must be done when you modify the URL structure of a page that is already ranking in the search engines. This is so you don't lose the ranking power of the old URL on the new URL.
Here is an example of a 301 redirect: Redirect 301 /oldurl/ http://your_domain.com/newurl/
and it is important to remember that you need to capture the redirect without the trailing slash as well like this: Redirect 301 /oldurl http://your_domain.com/newurl/
.
So for instance if this is the URL of you old page https://mathewlaverty.ca/blog/seo/
and you have changed the URL to https://mathewlaverty.ca/blog/search-engine-optimization/
then your full 301 redirect will be:
To redirect non-www to www
Do you want your website to appear as http://www.your_domain.COM rather then http://your_domain.COM then this is the redirect for you. It is important that you do this redirect or you will actually have 2 versions of your site indexing in Google. One with the www and one without.
To redirect www to non-www
Do you want your website to appear as http://your_domain.COM rather then http://www.your_domain.COM then this is the redirect for you. It is important that you do this redirect or you will actually have 2 versions of your site indexing in Google. One with the www and one without.
To redirect non-www to www (while using SSL)
Do you want your website to appear as https://your_domain.COM rather then https://www.your_domain.COM then this is the redirect for you. It is important that you do this redirect or you will actually have 2 versions of your site indexing in Google. One with https and one with http.
To redirect www to non-www (while using SSL)
Do you want your website to appear as https://your_domain.COM rather then https://your_domain.COM then this is the redirect for you. It is important that you do this redirect or you will actually have 2 versions of your site indexing in Google. One with https and one with http.