Regular Expressions 101

Community Patterns

Community Library Entry

1

Regular Expression
ECMAScript (JavaScript)

/
^(?=.*?[A-Za-z])(?=.*?[0-9])(?=.*?[a-zA-Z\d#?!@$%^&*+`~._\-\\\/;'"<>{}[\]]).{6,}$
/

Description

This regex checks if atleat a character and a number is there regardless of any special characters in the list

Submitted by Akshay Shah - 9 years ago