Date

The HTTP Date header indicates the date and time that the message was generated.

Usage

The format for the value of the HTTP Date header is:

Date: <day-name>, <day> <month> <year> <hour>:<minute>:<second> GMT

The Date header is created when the message is originated and includes several directives:

day-name

The day-name directive represents the day of the week and must be one of Mon, Tue, Wed, Thu, Fri, Sat, or Sun.

day

The day directive is the two-digit day of the month, such as 01 or 30.

month

The month directive is the three-character, case-sensitive name for the month. It must be one of Jan, Feb, Mar, Apr, May, Jun, Jul, Aug, Sep, Oct, Nov, or Dec.

year

The year directive is the four-digit number for the year, such as 2022.

hour

The hour directive is the two-digit number of the hour, in 24-hour format. Valid examples are 02 for 2:00 pm and 19 for 7:00 pm.

minute

The minute directive is the two-digit number for the minute, such as 06 or 59.

second

The second directive is the two-digit number for the second, such as 03 or 30.

GMT

The GMT directive stands for Greenwich Mean Time, which has no offset from Coordinated Universal Time (UTC). Dates are always expressed in GMT.

Example

The following example represents a date and time of Wednesday June 1st, 2022 at 8am UTC:

Date:  Wed, 01 Jun 2022 08:00:00 GMT

Deprecated date formats

The following date formats are obsolete:

Date: Sunday, 06-Nov-94 08:49:37 GMT
Date: Sun Nov  6 08:49:37 1994

Takeaway

The HTTP Date header contains the date and time that the message was created.

See also

Last updated: June 2, 2022