Page has unsuccessful HTTP status code

Page has unsuccessful HTTP status code

Appears in: SEO audits

Servers provide a three-digit HTTP status code for each resource request they receive. Status codes in the 400s and 500s indicate that there's an error with the requested resource. If a search engine encounters a status code error when it's crawling a web page, it may not index that page properly.

Key Term: Crawling is how a search engine updates its index of content on the web.

How the Lighthouse HTTP status code audit fails #

Lighthouse flags pages that return an unsuccessful HTTP status code (in the 400s or 500s):

Lighthouse audit showing search engines are struggling to index your page

Each SEO audit is weighted equally in the Lighthouse SEO Score, except for the manual Structured data is valid audit. Learn more in the Lighthouse Scoring Guide.

How to fix an unsuccessful HTTP status code #

First make sure you actually want search engines to crawl the page. Some pages, like your 404 page or any other page that shows an error, shouldn't be included in search results.

To fix an HTTP status code error, refer to the documentation for your server or hosting provider. The server should return a status code in the 200s for all valid URLs or a status code in the 300s for a resource that has moved to another URL.

If you're using Github Pages to host a single-page app, you'll likely need to serve valid content with a 404 status code.

Try it! Single-page applications can make fixing HTTP status code errors a bit more complicated. Learn how to fix sneaky 404s in an Express application.

Resources #


See it in action
Learn more and put this guide into action.
Last updated: Improve article