Regular Expressions 101

Community Patterns

Community Library Entry

1

Regular Expression
ECMAScript (JavaScript)

/
^(https?|ftp):\/\/[^\s/$.?#]+\.[^\s]+$|www\.[^\s/$.?#]+\.[^\s]+$|[^\s/$.?#]+\.[^\s]+$
/
gm

Description

Regex URL validation pattern

Submitted by Septian Maulana - a year ago