Regex Tester

Test your regular expressions with this online tool.

//g
0results

Common Regexes

Syntax Reference

Character Classes

  • .Any character (except newline)
  • \wWord character (a-z, A-Z, 0-9, _)
  • \dDigit (0-9)
  • \sWhitespace (space, tab, newline)
  • [abc]Any of a, b, or c
  • [^abc]Not a, b, or c
  • [a-g]Character between a & g

Anchors

  • ^Start of string/line
  • $End of string/line
  • \bWord boundary

Quantifiers

  • *0 or more
  • +1 or more
  • ?0 or 1
  • {3}Exactly 3
  • {3,}3 or more
  • {3,6}Between 3 and 6

Groups & Lookaround

  • (...)Capturing group
  • (?:...)Non-capturing group
  • $1First captured group

Test your regular expressions against any string with this online regex tester. Supports JavaScript regex.