Regular Expressions 101

Community Patterns

Strong Password

1

Regular Expression
PCRE (PHP <7.3)

/
^(?=.*?[0-9])(?=.*?[a-z])(?=.*?[A-Z])(?=.*?[^\w\s]).{8,20}$
/

Description

1 digit 1 lower case 1 upper case 1 special character (no-space) 8-20 length

Submitted by Femi Fapohunda - 8 years ago