Social

YouTube URL

Matches standard YouTube video URLs

/^(https?:\/\/)?(www\.)?(youtube\.com|youtu\.be)\/.+$/

Type in the box above to test if your input matches the regex pattern.

Test Cases

https://www.youtube.com/watch?v=dQw4w9WgXcQ
youtu.be/dQw4w9WgXcQ
google.com
vimeo.com

Tags

#social #video #url