12

I'm fixing some minor things on the 404 page for all my websites. My punctiliousness makes me unable to sleep well unless I get an answer to this question. :)

Does a 404 page need a meta description tag? If yes filled with what, "page not found"?

I would say no, if Google really cares more about contents and user frienly site rather than about what is on the page (moreover the 404 page snippet should never show up in Google cause server is sending real 404 code).

But after reading all this stuff:

on how they suggest to fill up a 404 page (that I always thought should just be a simple 404 page) I started to feel worried about meta description too.

  • 5
    Do you think your 404 page is going to rank well or drive in traffic? I didn't think so, either. :) – John Conde Nov 12 '10 at 19:53
17

The most important thing for your 404 pages is the header's status code: it must be 404 not found.

It's maybe stupid to say that, but in dynamics applications, with an URI like this http://my.webapp.invalid/index.php?id=4, when id=4 return nothing, many web developers returns a 404 message with a 200 OK status code...

An other thing: for example, if someone try http://my.webapp.invalid/index.php?id=toto whereas id only accept integer, it's not a 404, but a 400 Bad Request that you must return.

It's easy to handle this, for example, with the header function in PHP or the HttpWebResponse.StatusCode Property in .Net

  • Does that mean in the h1? – Daniel Springer Jan 28 '16 at 4:51
  • A 400 bad request usually indicates a protocol level problem with HTTP. Something like malformed headers. I wouldn't recommend using a 400 Bad Request status for an invalid parameter value. A "404 Not Found (What is this 'toto'??? I can't find it.)" would be fine. This StackOverflow answer suggests error codes 422 (Non-standard) or 403 (Understood, refused to fulfill) when the request syntax is correct, but has an invalid parameter. – Stephen Ostermiller Nov 7 '18 at 17:35
2

No. Why worry about your PR for your 404 page. I would be more worried on making sure none of your links end up there in the first place.

1

Meta information for a 404 page doesn't makes sense.

Return the proper 404 header is far way more important than any other technical measure.

From non-tech POV you should really consider returning useful information, instead of just an error message. Using the sitemap and internal search tools, providing some fruitful measures to your users makes much more sense (and make users happier, what makes your site better)

1

From a search engine POV you can even have an empty 404 error page. But your server must serve the correct status code (404 or 410) to say that the page the client is asking for no longer exist.

From a user POV having a well crafted error page is important because you don't want to let the user go away just because he, for example, followed a broken links: you want to give the user options to find his way on your website giving him for instance:

  • a search box
  • a link to the site map
  • a list of page similar to the one he was looking for (Google itself can help you)
  • a simple form to contact the webmaster

Since usually the content of the meta description tag is not visible to the user, It's absolutely OK if you don't fill it up.

0

I think it would make some sense to have robots defined. Specifically:

<meta name="robots" content="follow, noarchive, noindex">

(As in, “ignore this resource, but feel free to try others from the same domain.”)

Other meta data (like description, but also OpenGraph and Twitter Cards, et al), in my opinion, would make little to no sense and would only cost (some) bytes.

Admittedly, this is theoretical and somewhat speculative. If somebody knows of a resource that provides different insights, I’d love to know about it.

  • 2
    Search engines don't index 404 pages anyway. That meta tag wouldn't hurt anything, but it won't do anything either. – Stephen Ostermiller Nov 7 '18 at 17:36
  • If a 404 page has the proper headers this should indeed be the case. :) – ACJ Nov 8 '18 at 14:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.