On this page, there is an embedded YouTube video produced by code:

<iframe width="560" height="315" src="https://www.youtube.com/embed/1u17pS4_tw0?si=V06Ss5eD89_PBShj&controls=0&autoplay=1&rel=0&modestbranding=1&mute=1&loop=1" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe>

Note the &loop=1 parameter.

However the video on the page does not loop.

mickmackusa's user avatar

mickmackusa

49.2k13 gold badges98 silver badges165 bronze badges

Steve's user avatar

1

https://developers.google.com/youtube/player_parameters#loop:

Note: This parameter has limited support in IFrame embeds. To loop a single video, set the loop parameter value to 1 and set the playlist parameter value to the same video ID already specified in the Player API URL:

https://www.youtube.com/embed/VIDEO_ID?playlist=VIDEO_ID&loop=1

Just tested it, appears to work as advertised.

C3roe's user avatar

I believe you're missing the playlist parameter, which needs to be set to the video id, as explained in @C3roe's answer.

Note the added &playlist=1u17pS4_tw0, I've just tested it and it should work! :)

<iframe width="560" height="315" src="https://www.youtube.com/embed/1u17pS4_tw0?si=V06Ss5eD89_PBShj&controls=0&autoplay=1&rel=0&modestbranding=1&mute=1&loop=1&playlist=1u17pS4_tw0" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe>

Talos0248's user avatar

6 Comments

Please don't duplicate existing answers - Rather than posting the exact same answer, consider upvoting the answer instead

2025-11-27T08:15:26.483Z+00:00

This is not a duplicate of the answer — it provides an example solution

2025-11-27T09:06:20.887Z+00:00

I've tested your answer and I've modified the URL - in other to match the OP's video: https://www.youtube.com/embed/Lps7vHjUFUo?si=V06Ss5eD89_PBShj&controls=0&autoplay=1&rel=0&modestbranding=1&mute=1&loop=1&playlist=Lps7vHjUFUo.

2025-11-27T16:59:29.63Z+00:00

Oh, how strange! The iframe url shows up with the id 1u17pS4_tw0 for me. I tried out your url too and it seems to point to the same video. Thanks for the comment though — it helped me notice a mistake in my answer! (I changed controls to 1 for testing but accidentally flipped autoplay back instead lol)

2025-11-27T17:47:32.947Z+00:00

Upon further inspection, it seems they're slightly different videos! Was your video obtained from OP's linked website? I got mine from the iframe src from OP's question. If so, that definitely explains it :)

2025-11-27T18:11:09.123Z+00:00

Correct. I checked the OP's website for testing.

2025-11-27T18:50:07.74Z+00:00

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.