DD/MM/YYYY regex pattern

Copy and test a JavaScript regex for DD/MM/YYYY dates, with examples, limitations, and a one-click link to the regex tester.

DD/MM/YYYY regex pattern

Validate whole value

Use anchors to check whether the complete value matches.

Regex: ^(?:0[1-9]|[12]\d|3[01])\/(?:0[1-9]|1[0-2])\/\d{4}$

Flags: -

Search in text

Find matching fragments inside a larger block of text.

Regex: \b(?:0[1-9]|[12]\d|3[01])\/(?:0[1-9]|1[0-2])\/\d{4}\b

Flags: g

Examples that match

  • 31/12/2026
  • 05/01/2027

Examples that do not match

  • 31-12-2026
  • 2026/12/31

Limitations

This pattern matches date-like strings in DD/MM/YYYY form. Use date parsing for real calendar validation.