Google Lighthouse examines HTTP status codes to detect this problem. Scanning for error codes returning 400s and 500s, the system flags them and generates a warning. This warning appears as follows:
How to pass the audit? – Recovering unsuccessful HTTP status code
If you see this warning, you should make sure you have search engines crawling your page so you can pass this audit. It is extremely important that your pages shown as 404 or your pages with other error codes are not shown in SERP.
To achieve this, you may prefer to first browse the documentation of the hosting provider or the server you own. Here’s what the server should do:
- Returning a status code in the 200s (for valid URLs and for all of them)
- Returning a status code in 300s for a resource (one that has moved to another URL)
If you are using pages from Github for single-page applications, what you need to do is to provide valid content along with the 404 code.
Let’s give another note: If you are using single-page applications, it can sometimes take more effort to fix errors in HTTP codes. Therefore, you may need additional ideas to fix the 404s. Do not forget to take a look at the other content we have created to fix 404 errors.
Test Your Website Issues
You can quickly analyze your site