yigityalim
projectshandbookslabshireshare
xgithub
siteprojectshandbookslabschangelog
aboutusesnowhireshare
elsewherexgithublinkedinemail
metarssllms.txtsitemap
© 2026 Yiğit Yalım. All rights reserved.
/
Back to Labs
May 10, 2026·data

Regex Tester

Pattern + flag chips, live match highlighting, capture group breakdown, replacement preview. Everything runs in your browser — patterns never leave the page.

regex · validation · search

PreviousPassword Entropy MeterNextSHA-2 Hash Lab

The gap between learning regex and using it. Try patterns as you type, watch matches highlight live, see which captures land in which groups.

RegexTester2 matches
//
preview
Contact hello@example.com or sales@yigit.dev — invalid: bad@@test or @nodomain.
matches
  1. #11:9hello@example.com
  2. #21:30sales@yigit.dev

Flags quick reference

g global · all matches. i case insensitive. m multiline · ^ and $ bind to line boundaries. s dotall · . matches newlines. u unicode · enables \p{...} property escapes. y sticky · matches from lastIndex.

Common mistakes

  • Replace without g — only the first match is replaced. text.replace(regex, "x") is one-shot without the global flag.
  • Greedy quantifier — <.+> matches the whole "<a><b>" ; <.+?> is lazy and captures one tag.
  • Anchor escaping — string literals need "\\b"; regex literals use /\b/.
  • ReDoS — never build a regex from user input, or you're exposed to catastrophic-backtracking DoS attacks.