Skip to main content
>_devtools

Regex Cheat Sheet

Search regex syntax, replacement tokens, common patterns, and flavor differences with short worked examples.

What this does

Search a reference of regex tokens, common patterns, replacement syntax, and flavor differences. Select a topic or search term to find a short explanation and checked example.

Example

\d\d\d\d-\d\d-\d\d → four digits, hyphen, two digits, hyphen, two digits

Limits and behavior

  • Examples use JavaScript syntax unless a different regex flavor is named; matching a date shape does not validate a calendar date.