Regular Expressions 101

Save & Share

  • Save Regex
    ctrl+s
  • Update Regex
    ctrl+⇧+s

Flavor

  • PCRE2 (PHP >=7.3)
  • PCRE (PHP <7.3)
  • ECMAScript (JavaScript)
  • Python
  • Golang
  • Java 8

Function

  • Match
  • Substitution
  • List
  • Unit Tests
"
[^u]es|ma$|mo|y|[mie]e|wi|ter|au
"
gm
1st Alternative
[^u]es
Match a single character not present in the list below
[^u]
u matches the character u with index 11710 (7516 or 1658) literally (case sensitive)
es
matches the characters es literally (case sensitive)
2nd Alternative
ma$
ma
matches the characters ma literally (case sensitive)
$ asserts position at the end of a line
3rd Alternative
mo
mo
matches the characters mo literally (case sensitive)
4th Alternative
y
y matches the character y with index 12110 (7916 or 1718) literally (case sensitive)
5th Alternative
[mie]e
Match a single character present in the list below
[mie]
mie
matches a single character in the list mie (case sensitive)
e matches the character e with index 10110 (6516 or 1458) literally (case sensitive)
6th Alternative
wi
wi
matches the characters wi literally (case sensitive)
7th Alternative
ter
ter
matches the characters ter literally (case sensitive)
8th Alternative
au
au
matches the characters au literally (case sensitive)
Global pattern flags
g modifier: global. All matches (don't return after first match)
m modifier: multi line. Causes ^ and $ to match the begin/end of each line (not only begin/end of string)
Your regular expression does not match the subject string.

Regular Expression
No Match

r"
"
gm

Test String