StocksR
StocksR

Reputation: 993

Http Status Code 301 to a page that return 410

I have been asked by a client to return a 410 Status code for some URLs in a previous version of there site.

I have two options for how to programe this (based on constraints outside the scope of this request)

Option 1 this is easy to implement: use an existing old urls redirector (301 status code) to redirect all those urls to a single page, and have that page return an (410 status) code.

Option 2 harder to implement: write a feature to return the 410 status codes directly.

The question: will google(and others) do the right thing with option 1?

Upvotes: 1

Views: 704

Answers (2)

Aurélien Bottazini
Aurélien Bottazini

Reputation: 3309

I am pretty sure google will tag your page as 301 with option 1.

Option 2, even if harder feels much safer (but you already know that :))

Upvotes: 1

Jeremy B.
Jeremy B.

Reputation: 9216

You'll probably want to return the 410 directly, unless you are 100% there are no possible client connections made to the site which cannot correctly interpret the 301.

I would opt for the direct 410 to keep http integrity.

Upvotes: 2

Related Questions