What is the 410 Error page and how to set up?

Should you use 410 or 404 Error page?

404 or 410 status Errors are for specific pages that do no longer exist. However, 410 is for pages that are gone, and you probably don't intend to recreate them. On the other hand, 404 error pages are for not found pages. The purpose of this article is to discuss how Search Engines treat both error status. We will also see how you can configure them on your website. Finally, we will talk about the advantages of using one compared to the other.

What is the 410 Error page and how to set up?

410 Error page means the page is gone. In order words, if you have a page that will no longer exist, you can use the 410 gone pages. 410 error page is used to specify that a page a permanently removed and will not come back. I will probably recommend the 410 Error page to eCommerce businesses or companies that run websites with URLs that are continually changing. Setting up the 410 Gone pages may vary depending on the server. But, if you are hosting your site on a server that supports the .htaccess file, this is how you can configure your 410 gone pages.
  • You need to add this small code to your .htaccess file.
Redirect gone /path/to/folder/
ErrorDocument 410 default(or 410 file)
In the code above, /path/to/folder/ represent that folder or absolute URL that you permanently deleted. For example, if you removed the page website-development, that is like https://www.prositeweb.ca/website-development, you can replace the /path/to/folder/ by /website-development. Moreover, the "default" in the second line will display the following message:

Gone

The requested resource /website-development is no longer available on this server, and there is no forwarding address. Please remove all references to this resource.
As you can see the message is not formatted or uniform to your website. But with a little customization and styling, you can create an excellent looking 410.php(.html or whatever you want) page. Once you do that, instead of "default" in the second line, you can add the path to the page you created.

What is the 404 Error page and how to set up?

I believe most of us are used to 404 Error pages as you may have seen it once or twice on websites. It just specifies that a page is not found. There are many options when a page is redirected to a 404 not found:
  • The page might no longer exist
  • You may have added the wrong URL to the anchor
  • The page may have been deleted temporary
It is essential also to configure the 404 not found page so that your visitors will not fall on a blank page when an error occurred.  For the 404 not found page, many CMS already have an easy way that users can use. For example, if you are using WordPress, you need to create a 404.php file and add it to your template. To use the .htaccess to set up your 404 not found page in case you are not using a CMS or framework, add this code to your .htaccess file ErrorDocument 404 /errordocs/404.html In that line of code, 404.html represents pieces of information that will be displayed if your visitors land to a not found page.

How do Search Engines like Google handle 404 or 410 pages?

According to John Mueller, who is the senior Webmaster Trends Analyst at Google, Google handles the 410 and 404 error pages the same way. This is an extract of the advice that he gave regarding the way to handle 404 and 410 status. The block of the article below is taken from Search Engine Journal: “If a 404 error goes to a page that doesn’t exist, should I make them a 410?” John Mueller answered:   “From our point of view, in the midterm/long term, 404 is the same as a 410 for us. So in both of these cases, we drop those URLs from our index. We generally reduce crawling a little bit of those URLs so that we don’t spend too much time crawling things that we know don’t exist. The subtle difference here is that a 410 will sometimes fall out a little bit faster than a 404. But usually, we’re talking on the order of a couple of days or so. So if you’re removing content naturally, then that’s perfectly fine to use either one. If you’ve already dismissed this content long ago, then it’s already not indexed, so it doesn’t matter for us if you use a 404 or 410.”  

Conclusion

If you intend to delete a page permanently, you can use the 410 Error page. That can reduce a little bit the number of the crawl of those pages. But for pages that you delete temporary, 404 is probably better. Thanks for reading. If you have questions, or you need help to set up your 410 error page, please, contact us.