Back to all tools
Regex
Regex Cheat Sheet
Quick reference for regex tokens
| Token | Meaning |
|---|---|
| . | Any character except newline |
| \d | Digit (0–9) |
| \D | Non-digit |
| \w | Word character |
| \s | Whitespace |
| ^ | Start of string |
| $ | End of string |
| * | 0 or more |
| + | 1 or more |
| ? | 0 or 1 |
| {n,m} | Between n and m |
| (abc) | Capturing group |
| (?:abc) | Non-capturing group |
| [abc] | Character set |
| [^abc] | Negated set |
| a|b | Alternation |
| \b | Word boundary |