The ETag header is a part of the HTTP/1.1 specification. Every resource on a server has its own ETag. Whenever a resource is modified, its ETag is changed — this allows clients to check to see whether their user's bookmarks have altered since they were last viewed.

The ETag should be unique for the lifetime of the resource. Often, it is a simple hash of the date and time of the file's modification.

RFC 2616 (HTTP/1.1) has this to say about the ETag:

The ETag response-header field value, an entity tag, provides for an "opaque" cache validator. This might allow more reliable validation in situations where it is inconvenient to store modification dates, where the one-second resolution of HTTP date values is not sufficient, or where the origin server wishes to avoid certain paradoxes that might arise from the use of modification dates.

Log in or register to write something here or to contact authors.