How to fix the Youtube iframe loop not working with HTML?

Spread the love

To fix the Youtube iframe loop not working with HTML, we add the playlist query parameter.

For instance, we write

<iframe
  class="embed-responsive-item"
  id="ytplayer"
  type="text/html"
  width="640"
  height="360"
  src="https://www.youtube.com/embed/M7lc1UVf-VE?&autoplay=1&loop=1&rel=0&showinfo=0&color=white&iv_load_policy=3&playlist=M7lc1UVf-VE"
  frameborder="0"
  allowfullscreen
></iframe>

to add the playlist parameter to the embed video URL to autoplay the playlist loop.

Leave a Reply

Your email address will not be published. Required fields are marked *