Connect with us

Hi, what are you looking for?

Web

How to do a 301 Redirect

It often happens that web pages disappear or change their address on a website. When this happens, it is necessary to notify the engines to indicate the procedure to follow and, in particular, to present them with the new address of the page. However, there are several ways to establish this signage. So, here’s a PRposting tutorial explaining how to set up an effective redirect for your SEO.

What is a 301 redirect?

If you move a page on your site all the time, it is essential to use 301 redirects. The 301 redirections will make the second address disappear in favor of the good one while keeping the elements helpful in referencing/positioning. Search engines interpret this redirect well and automatically update their index by replacing the old URL with the new one. However, it may take a few weeks before it is considered.

How to do a 301 redirect?

The 301 code was implemented in the HTTP protocol to allow website managers to provide a better user experience to Internet users. Technically speaking, the best way to use a 301 Redirect is to change the server level in the .htaccess file.

This file is the first to be read by your Apache web server when a request is routed, so it is the best place to redirect all traffic. Using this code is even more appreciated by search engines, as it clearly and transparently determines its intention to redirect a web page. The 301 code can be entered in 3 different ways in the .htaccess file of your server:

  • Redirect 301 /old-address-1
  • Redirect Permanent /old-address-2
  • Redirect Permanent /old-address-3

It is advisable to avoid Javascript redirects, which can be considered spam, and the meta refresh tag.

Test its operation

The last step before closing your redirection work is, of course, to do a test to verify that the URLs work correctly. Several resources allow you to do these tests:

Another method to see if the permanent redirection is working is to type the old address of the page concerned. If you find the new address, then you have succeeded in your 301 mission! On the other hand, if you have a 404 error page, then there is a problem, and you need to fix it quickly. Moreover, be aware that an address responding in 404 will be quickly downgraded because Google tries not to offer empty pages to Internet users.

If you have any questions about the redirects in this tutorial, feel free to ask our experts.

Written By

Thanks for reading this article. If you're new here, why don't you subscribe for regular updates via RSS feed or via email. You can also subscribe by following @techsling on Twitter or becoming our fan on Facebook. Thanks for visiting!

Click to comment

Leave a Reply

Your email address will not be published. Required fields are marked *

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

You May Also Like