Date Format

Grep Badger's UI is built with Angular, so the custom date format uses Angular date formatting.

This means the value you enter follows Angular's DatePipe format rules, which are based on Unicode date field patterns.

This is not a .NET DateTime format string reference. Some patterns look similar, but not all .NET tokens work the same way here.

Default format

The default timestamp format is:

HH:mm:ss

Example output:

14:07:32

Common examples

What you wantFormatExample output
24-hour timeHH:mm:ss14:07:32
12-hour time with AM/PMhh:mm:ss a02:07:32 PM
Date onlyMMM d, yyyyApr 19, 2026
Short dateM/d/yy4/19/26
Date and timeyyyy-MM-dd HH:mm:ss2026-04-19 14:07:32
Date and time with millisecondsyyyy-MM-dd HH:mm:ss.SSS2026-04-19 14:07:32.123
Full month nameMMMM d, yyyyApril 19, 2026
Weekday includedEEE, MMM d, yyyy HH:mmSun, Apr 19, 2026 14:07
Built-in short formatshort4/19/26, 2:07 PM
Built-in medium formatmediumApr 19, 2026, 2:07:32 PM

Pattern reference

The table below covers the most useful Angular date format tokens.

FieldFormatDescriptionExample
EraG, GG, GGGAbbreviated eraAD
GGGGWide eraAnno Domini
GGGGGNarrow eraA
YearyNumeric year, minimum digits2026
yy2-digit year26
yyy3-digit year2026
yyyy4-digit year2026
MonthMNumeric month4
MM2-digit month04
MMMAbbreviated month nameApr
MMMMWide month nameApril
MMMMMNarrow month nameA
Day of monthdNumeric day9
dd2-digit day09
WeekdayE, EE, EEEAbbreviated weekdaySun
EEEEWide weekdaySunday
EEEEENarrow weekdayS
EEEEEEShort weekdaySu
AM/PMa, aa, aaaAM/PM markerPM
aaaaWide AM/PM markerp.m.
aaaaaNarrow AM/PM markerp
Hour (1-12)hNumeric hour, 1-122
hh2-digit hour, 1-1202
Hour (0-23)HNumeric hour, 0-2314
HH2-digit hour, 0-2314
MinutemNumeric minute7
mm2-digit minute07
SecondsNumeric second3
ss2-digit second03
Fractional secondsSTenths of a second1
SSHundredths of a second12
SSSMilliseconds123
Time zonez, zz, zzzShort specific non-location formatGMT-4
zzzzLong specific non-location formatGMT-04:00
Z, ZZ, ZZZISO8601 basic format-0400
ZZZZZISO8601 extended format-04:00
O, OO, OOOShort localized GMT formatGMT-4
OOOOLong localized GMT formatGMT-04:00

Predefined format names

Angular also supports a few built-in format names.

Format nameExample output
shortDate4/19/26
mediumDateApr 19, 2026
longDateApril 19, 2026
fullDateSunday, April 19, 2026
shortTime2:07 PM
mediumTime2:07:32 PM
longTime2:07:32 PM GMT-4
fullTime2:07:32 PM GMT-04:00
short4/19/26, 2:07 PM
mediumApr 19, 2026, 2:07:32 PM
longApril 19, 2026 at 2:07:32 PM GMT-4
fullSunday, April 19, 2026 at 2:07:32 PM GMT-04:00

Literal text

Use single quotes to include plain text in the result.

Example:

  • Format: 'Time:' HH:mm:ss
  • Output: Time: 14:07:32

Another example:

  • Format: MMM d, yyyy 'at' HH:mm
  • Output: Apr 19, 2026 at 14:07

Tips

  • If you want a simple log timestamp, use HH:mm:ss
  • If you want milliseconds, add .SSS
  • If you want AM/PM, use a
  • If you want month names, use MMM or MMMM
  • If a format does not behave as expected, make sure you are using Angular date tokens rather than .NET date tokens

Quick copy/paste formats

HH:mm:ss
HH:mm:ss.SSS
hh:mm:ss a
MMM d, yyyy
MMM d, yyyy HH:mm:ss
yyyy-MM-dd HH:mm:ss
yyyy-MM-dd HH:mm:ss.SSS
EEE, MMM d, yyyy HH:mm