Don't like ads? Go Ad-Free Today

Regex Cheatsheet

DeveloperText
ADVERTISEMENT · REMOVE?
ADVERTISEMENT · REMOVE?

Guide

Regex Cheatsheet

Regex Cheatsheet

A comprehensive, searchable quick reference guide for regular expression syntax and common patterns. Whether you are writing validation rules, parsing log files, or doing text transformations, this cheatsheet gives you instant access to the regex patterns you need.

How to Use

Browse through the categorized tables to find the regex syntax you need. Use the search box to filter patterns by name, description, or example. Select a specific category from the dropdown to narrow your view. Click the copy button next to any pattern to copy it to your clipboard.

Features

  • 7 Categories – Anchors, character classes, quantifiers, groups and references, lookahead and lookbehind, flags, and common patterns
  • Instant Search – Filter all patterns in real-time by typing in the search box
  • Category Filter – Focus on a specific category to find what you need quickly
  • Copy to Clipboard – One-click copy for every pattern
  • Practical Examples – Each pattern includes a real-world usage example

What is the difference between greedy and lazy quantifiers?

Greedy quantifiers (* + {n,m}) match as many characters as possible, while lazy quantifiers (*? +? {n,m}?) match as few characters as possible. For example, given the string bold, the greedy pattern <.*> matches the entire string, while the lazy pattern <.*?> matches only .

What is the difference between a capturing group and a non-capturing group?

A capturing group (abc) saves the matched text so it can be referenced later with backreferences like \1 or in replacement strings. A non-capturing group (?:abc) groups elements together for quantifiers or alternation without saving the match, which is more efficient when you do not need the captured value.

What are lookahead and lookbehind assertions?

Lookahead (?=…) and lookbehind (?<=...) are zero-width assertions that check whether a pattern exists ahead of or behind the current position without consuming any characters. Negative versions (?!...) and (?

ADVERTISEMENT · REMOVE?
Want To enjoy an ad-free experience? Go Ad-Free Today

Install Our Extensions

Add IO tools to your favorite browser for instant access and faster searching

Add to Chrome Extension Add to Edge Extension Add to Firefox Extension Add to Opera Extension

Scoreboard Has Arrived!

Scoreboard is a fun way to keep track of your games, all data is stored in your browser. More features are coming soon!

ADVERTISEMENT · REMOVE?
ADVERTISEMENT · REMOVE?
ADVERTISEMENT · REMOVE?

News Corner w/ Tech Highlights

Get Involved

Help us continue providing valuable free tools

Buy me a coffee
ADVERTISEMENT · REMOVE?