HTTP status Code 2XX, 3XX, 4XX, 5XX analysis

Source: Internet
Author: User
Keywords http

Intermediary transaction SEO diagnosis Taobao guest Cloud host technology Hall

Returns an HTTP status code that is the state of the server displayed on your Web site in response to a request, for example:

• When a user accesses a Web page in a browser.

• When search engine spiders crawl Web pages.

The HTTP status code is five different categories:

1XX Temporary/Information response

2XX success

3XX redirect

4XX Client/Request Error

5XX Server Error

The first number of five categories of response status codes is the only representative.

HTTP status Code

Google Webmaster provides a list of HTTP status codes, the most common and important status codes are as follows:

200 (successful), the server successfully processed the request. In general, this means that the server provides the requested page, and if you see this state, your robots.txt file, which means that Googlebot's retrieval was successful.

301 (permanently moved), the requested Web page has been permanently moved to a new location, and when the server returns this response (as a response to a GET or head request), it automatically forwards the request to the new location. You should use this code to let Googlebot know that a Web page or Web site has been permanently moved to a new location.

302 (temporary move), the server is responding to requests from different locations of pages, but the requester should continue to use the original location for future requests. This code is similar to 301 in this get or head request, it will automatically forward to a different location request, but you should not use it to tell Googlebot that a Web page or site has moved because Googlebot will continue to crawl and index the original location.

400 (Error request), the server does not understand the syntax of the request.

403 (prohibited), the server refused the request. If you see a valid page in Googlebot trying to crawl your site (you can see the crawl page on the web in Google Webmasters Diagnostics) When you receive this status code, it may be your server or host preventing Googlebot access.

404 (Not found), the server could not find the requested page. For example, the server returns this code if the request is on the server and the page does not exist. This is the correct state if you do not have the robots.txt file on your site and you see this status on the robots.txt page of the Webmasters Diagnostics tab. However, if you have a robots.txt file that you will see in this state, then your robots.txt file may be named incorrectly or in the wrong place. It should be in the top-level domain, named robots.txt. If you see the URL, Googlebot tries to crawl (diagnose "label HTTP Error" page) This state, then indicates that Googlebot may be an invalid link from another page (possibly an old link or incorrect input).

500 (internal server error), the server encountered an error and could not meet the requirements.

503 (Service Unavailable), the server is currently unavailable (because it is overloaded maintenance or downward), in general, this is a temporary state.

Search engine optimization for HTTP status codes

Administrators can periodically review HTTP status codes and search engine spiders in IIS log files (if the Web site is running Internet Information Services). HTTP status codes for other sources:

• About Google search engine optimization, webmaster main purpose is to increase Google's PageRank (link juice) or maintain its web page of Google's PageRank value. Only return pages using HTTP status Codes 200 and 301 are Google seo friendly and can be via link juice.

· SEO terminology, including definitions of 301,302 and 404 HTTP Status codes and many other definitions, about SEO.

· has a complete list of HTTP status codes.

HTTP Status Code 301

The test shows that Google admits 301 redirect pages of redirect and pass-link juice redirected to the page, Google SEO traffic will not be lost.

Set up 301 Redirect to Microsoft's Internet Information Server (MS IIS):

• You can redirect a domain or a personal page.

• You will need a source code page or website, as well as a target page or website.

• You can create redirects using the IIS Control Panel.

To establish in Apache301 redirection:

• You will need a source code page or website, as well as a target page or website.

• When you install the mod_rewrite extension by default, you need to redirect the. htm file from the old server, equivalent to the. php file, using the 301 redirect to a new server, using the mod_rewrite combination and redirect instructions to do URL changes and redirects.

• Syntax for using htaccess file redirection directives: redirect Permanent/yourdirectory, or redirect 301/yourdirectory http://

The test example shows that it has not previously involved the redirection specification's hostname, and redirects 301 redirects from one domain to another.

HTTP Status Code 404

I want the webmaster to handle 404 errors:

• The definition should return a 404 response code for "files not found" requirement.

• Explain "hard 404" and "soft 404" and recommend avoiding back to "soft 404". "Soft 404" occurs when a user requests a URL that does not exist on your site, but the server returns an error message and a Web page with an HTTP status code.

·“ Soft 404 "may confuse users and search engine spiders, leading to googlebot crawling and indexing your site for nonexistent and repetitive URLs that take unnecessary time."

• Google provides soft 404 reporting functionality under the Crawl error section of Google Webmaster tools.

In order to improve user friendliness, the webmaster can set the server to return a nice 404 error page.

I come from a gauze net (life a yarn, the article for original, reprint please indicate the source.

Original link:

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.