There is a very annoying situation when you browse the Internet: when you think you have found what you were looking for, you click and face a 404 error, page not found.
In the past, I talked about why it is essential to perform a good web maintenance. A web page is something alive and in permanent change. That means that, eventually we can delete a section or modify its name, and with that its address. At that time we must be attentive to all incoming links. We can modify them manually, but it would take a lot of work and we can leave some. This is where redirection 301 comes into play.
What is a 301 redirection?
Why? you may already know that broken links are one of the elements that will penalize our site in the face of SEO positioning. The great advantage is that the redirect 301 transmits the whole value of the link from the old page to the new one, it automatically eliminates the old index and the new one is included, so that the search engines take it into account much more. fast
How to create a 301 redirect
Redirecting a URL may seem a somewhat complicated task, but in this case it is not so complicated, especially considering the great benefits it has. For this you have to edit a file that is on the server called “.htaccess”. You will find it at the root of your website and it is the first thing that loads when a user accesses your site. It is a fundamental piece of your site and very sensitive, so before touching it make a backup copy.
Once you have done it:
- Access the file: You must do it through an FTP system (acronym in English mean file transfer protocol) to your server. It is a hidden file, so you must enable the option to view all files. You can open it with any text editor.
- Edit it: At the end of the file, write, and respect the spaces or you will have an error 500: redirect 301 / (Old URL) / /www.url.com/(URL new) /
- Save it: Use an ANSI encoding so that no error occurs.
As we have already said, it is a permanent redirect, so you should not have to change it, but the web pages change and you may be forced to make new changes. In any case, try to keep it at least for a year so that the search engines position you well.
I hope this post has clarified ideas about 301 redirections!