Regex Cheat Sheet
A concise regular-expression cheat sheet covering character classes, anchors, quantifiers, groups, lookaround and flags. Runs in your browser.
How to use Regex Cheat Sheet: Open Regex Cheat Sheet — it runs entirely in your browser with no setup. Paste or type your input into the text area, or upload a file where supported. Set any options you need. The result appears in the output panel — there is no upload step and no waiting on a server. Everything runs inside your browser, so your data never leaves your device.
Character classes
. | Any character except newline |
\d \D | Digit / non-digit |
\w \W | Word char / non-word char |
\s \S | Whitespace / non-whitespace |
[abc] | Any of a, b or c |
[^abc] | Not a, b or c |
[a-z] | Range a to z |
Anchors
^ | Start of string / line |
$ | End of string / line |
\b \B | Word boundary / non-boundary |
Quantifiers
* | 0 or more |
+ | 1 or more |
? | 0 or 1 (optional) |
{n} | Exactly n |
{n,} | n or more |
{n,m} | Between n and m |
*? +? | Lazy (non-greedy) versions |
Groups & lookaround
(abc) | Capturing group |
(?:abc) | Non-capturing group |
(?<name>…) | Named group |
a|b | Alternation (a or b) |
(?=…) | Positive lookahead |
(?!…) | Negative lookahead |
(?<=…) | Positive lookbehind |
(?<!…) | Negative lookbehind |
Flags
g | Global — all matches |
i | Case-insensitive |
m | Multiline ^ and $ |
s | Dotall — . matches newline |
u | Unicode |
y | Sticky |
A concise regular-expression cheat sheet covering character classes, anchors, quantifiers, groups, lookaround and flags. Runs in your browser. Regex Cheat Sheet is a free, browser-based tool in the Filevane developer tools collection — there is nothing to install, no account to create and no watermark on your results. It works on desktop, tablet and mobile, and because the work happens on your own device it stays fast even with large inputs.
How to use Regex Cheat Sheet
- Open Regex Cheat Sheet — it runs entirely in your browser with no setup.
- Paste or type your input into the text area, or upload a file where supported.
- Set any options you need. The result appears in the output panel — there is no upload step and no waiting on a server.
- Review the output instantly; large inputs are handled locally without lag.
- Copy the result to your clipboard or download it. Your data never leaves the page.
Why use Regex Cheat Sheet?
- 100% free with no limits, no sign-up and no watermarks.
- Private by design — your data are processed in your browser and never uploaded to a server.
- Fast and lightweight, with instant results even on a phone or a slow connection.
- Works everywhere — any modern browser on Windows, macOS, Linux, Android or iOS.
- Part of a full developer tools suite, so related regex cheat sheet tasks are one click away.
What people use Regex Cheat Sheet for
- Looking up a token you half-remember while writing a pattern.
- Checking whether a construct exists in the flavour you are targeting.
- Learning the syntax by seeing the pieces grouped by purpose.
Regex Cheat Sheet: limits and things worth knowing
- \d matches Unicode digits beyond 0-9 in some flavours and only ASCII in others. When it matters, [0-9] states exactly what you mean.
- The dot matches any character except a newline unless the dotall or s flag is set — the single most common reason a multi-line pattern fails.
- Quantifiers are greedy by default and match as much as possible; adding ? makes them lazy. This is what separates <.+> from <.+?> on a line with two tags.
- Inside a character class most metacharacters lose their special meaning, so [.] is a literal dot and needs no escape.
Is it private and secure?
Your privacy is built in. Regex Cheat Sheet runs completely on your device, so whatever you enter stays in your browser and is never transmitted, logged or stored on any server.
Network activity: none. Nothing is sent and nothing is fetched. This tool makes no network request at all once the page has loaded — which is why it keeps working if your connection drops.
You do not have to take that on trust — our privacy proof page publishes the Content-Security-Policy that enforces it, lists every third party it permits, and shows how to verify the whole claim yourself.
Learn more
Is It Safe to Paste Production Data Into Online Tools? — JWTs, API responses and env files get pasted into online formatters every day. Here's what actually happens to that data and how to check before you paste.
Related tools
See all free developer tools or browse the full tool catalogue.