A 301 redirect is the most reliable way to create a permanent redirection from one URL to another. It’s useful for funneling your link juice as well as when you completely change the destination of a web site or page. In this article we’ll talk more about what is a 301 redirect and give an example of why and how you would use it.
What is a 301 Redirect?
First, let’s answer the most obvious question of what is a 301 redirect using an example.
A common example of a use of a 301 is when you want to group two similar URLs together such as “example.com” and “www.example.com” because search engines consider the two different despite the fact that they lead you to the same site.
You never know if someone off of your site when linking to you will use one or the other, so it’s a good idea to just tell search engines clearly that they’re the same using a 301 so that you get the link juice to your site no matter which people use when linking.
Also, unlike other forms of redirects, search engines do not penalize 301’s the way they do others, so it’s the safest form of redirection, as well.
How to Make a 301 Redirect:
- Create a .htaccess file by opening notepad and naming the filing .htaccess (without extension. If you already have a .htaccess file on your server, download it for editing.
- Place this code in your .htaccess file: redirect 301 /old/old.htm http://www.example.com/new.htm
- Note that there is no “http://www.” in the old URL and the exact locations in the code should be changed to reflect your site (duh).
- If you already have code in an existing .htaccess file, skip a line then add the code. Make sure “word wrap” is off if you’re doing this in notepad as that should be one line of code.
- Save the file, then upload it to the root folder of your server. When you test the old URL in your internet browser, you should be taken to the new URL.
How to Do a 301 Redirect With a Plugin
Conversely, you can use a number of plugins to easily create a redirect. A free plugin like Pretty Link allows you to create redirects from the old page to the new page.
When creating a redirect link, you can choose to designate it as 301 which again denotes a permanent link.
Of course a 301 isn’t the only type of redirect, so check out my comparison of the 301 vs 302 vs 307 redirects.