.Any character except newline (without s flag)
\d \w \sDigit, word char ([A-Za-z0-9_]), whitespace
\D \W \SNegations of the above
^ $Start / end of input (per line with m)
\b \BWord boundary / non-boundary
[abc] [^abc]Character class / negated class
a* a+ a?0+, 1+, 0 or 1 of a
a{2,5}Between 2 and 5 of a
(abc)Capturing group → backref $1
(?<name>abc)Named group → backref $<name>
(?:abc)Non-capturing group
(?=abc)Positive lookahead
(?!abc)Negative lookahead
(?<=abc)Positive lookbehind
a|bAlternation
\\Escape a literal metacharacter