The Mutt E-Mail Client : Advanced Usage : Patterns : Searching by Date
Previous: Complex Patterns
Next: Using Tags

## 4.2.3. Searching by Date

Mutt supports two types of dates, absolute and relative.

Absolute. Dates must be in DD/MM/YY format (month and year are optional, defaulting to the current month and year). An example of a valid range of dates is:

> `

>     Limit to messages matching: ~d 20/1/95-31/10

> `

If you omit the minimum (first) date, and just specify ``-DD/MM/YY'', all messages before the given date will be selected. If you omit the maximum (second) date, and specify ``DD/MM/YY-'', all messages after the given date will be selected. If you specify a single date with no dash (``-''), only messages sent on the given date will be selected.

Relative. This type of date is relative to the current date, and may be specified as:

- >offset (messages older than offset units)
- <offset (messages newer than offset units)
- =offset (messages exactly offset units old)

offset is specified as a positive number with one of the following units:

    y       years
    m       months
    w       weeks
    d       days

Example: to select messages less than 1 month old, you would use

> `

>     Limit to messages matching: ~d <1m

> `

Note: all dates used when searching are relative to the local time zone, so unless you change the setting of your $index_format to include a `%[...]` format, these are not the dates shown in the main index.

The Mutt E-Mail Client : Advanced Usage : Patterns : Searching by Date
Previous: Complex Patterns
Next: Using Tags