i
Hate
Regex
Library
Cheatsheet
Community
Open playground
match a username
Regex title
Edit anything to remix
Remix in playground
JavaScript
Expression
/
Regular expression
^
[a-z0-9_-]
{3,15}
$
^[a-z0-9_-]{3,15}$
/
gm
g
i
m
s
u
y
flags
Test bench
Sample text
6 matches
lorem
ipsum
gr3at
a ab
abcd
abcde
john doe
johnny
abcdefghijklmnopqrst
lorem ipsum gr3at a ab abcd abcde john doe johnny abcdefghijklmnopqrst
Structure
Railroad diagram
Interactive
SVG
PNG
Copy
Embed
Live
Strings that match
lorem
ipsum
gr3at
abcd
abcde
johnny
Strings that don’t match
a
ab
john doe
abcdefghijklmnopqrst
Related patterns
url slug
match a url slug