Youtube Video Link Regular Expression

Category: URI | Views Total: 2 views

A regular expression that matches all valid Youtube Video Links (short links are supported as well).

/http(?:s?):\/\/(?:www\.)?youtu(?:be\.com\/watch\?v=|\.be\/)([\w\-\_]*)(&(amp;)?[\w\?=]*)?

Youtube Video Link Example:

  • http://www.youtube.com/watch?v=BeG_UU-Bf5k
  • https://www.youtube.com/watch?v=BeG_UU-Bf5k
  • http://youtu.be/BeG_UU-Bf5k

See Also:

Rate This Regex
Sending
User Review
0 (0 votes)

Leave a Reply