# How to stop music that is playing

**URL:** <https://forum.makecode.com/t/how-to-stop-music-that-is-playing/32514>\
**Category:** Help\
**Tags:** game\
**Created:** [December 16, 2024, 2:14am UTC](https://forum.makecode.com/t/how-to-stop-music-that-is-playing/32514 "2024-12-16T02:14:55Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![AgentBoom](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/agentboom/32/16635_2.png) [@AgentBoom](https://forum.makecode.com/u/AgentBoom)\
**Post date:** [December 16, 2024, 2:14am UTC](https://forum.makecode.com/t/how-to-stop-music-that-is-playing/32514/1 "2024-12-16T02:14:55Z")

</div>

Hello! I’ve been working on a game recently, and everything was going smoothly, but now I’m stuck with a problem:  
How can I make music that is playing in a loop, like this:

 ![Screenshot 2024-12-14 14.05.10](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/3X/e/0/e06c8a4807f7407d4b94b36e090ac3fce275f195.png)  
Stop? I’ve tried the stop sounds block, but I really can’t think of anything else to do… Help, please!

---

<div class="post-metadata">

**Author:** ![ADM\_F](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/adm_f/32/19808_2.png) [@ADM\_F](https://forum.makecode.com/u/ADM_F)\
**Post date:** [December 16, 2024, 6:29pm UTC](https://forum.makecode.com/t/how-to-stop-music-that-is-playing/32514/2 "2024-12-16T18:29:23Z")

</div>

When you stop all sounds it goes to the next song because it just ended the one playing

You could just make the stop all sounds repeat alot, should work ill see if there is a better way

---

<div class="post-metadata">

**Author:** ![AMakerOfBadGames](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/amakerofbadgames/32/27156_2.png) [@AMakerOfBadGames](https://forum.makecode.com/u/AMakerOfBadGames)\
**Post date:** [December 16, 2024, 6:36pm UTC](https://forum.makecode.com/t/how-to-stop-music-that-is-playing/32514/3 "2024-12-16T18:36:15Z")

</div>

Stop all sounds only works once but since their other songs lined up it skips the song playing at the moment and move on to the next one  
**A way** I’ll fix it is using a lot of logic blocks, to do this make it where all of the songs are in their own logic block so when ever you leave the menu the InMainMenu is = to 0 it will skip over one of them, then the other, then so far and so on  
(Sorry I’m bad at this kind of stuff and this may be confusing if you do understand this someone else will help you better than me)

---

<div class="post-metadata">

**Author:** ![AgentBoom](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/agentboom/32/16635_2.png) [@AgentBoom](https://forum.makecode.com/u/AgentBoom)\
**Post date:** [December 16, 2024, 8:12pm UTC](https://forum.makecode.com/t/how-to-stop-music-that-is-playing/32514/4 "2024-12-16T20:12:43Z")

</div>

Thanks everyone! @ADM_F, I tried what you said, but sadly it didn’t work; instead it just replayed the song. I don’t know why.  
@AMakerOfBadGames, I’m afraid that’s not the result that stopping sounds makes. Instead it just moves to the beginning. But you’re idea is good! I’ll try it out.  
Result: IT WORKED! HOORAY! Thank you so much @AMakerOfBadGames, and @ADM_F, it sadly didn’t work, but thanks for taking the time to write a reply!

---

<div class="post-metadata">

**Author:** ![AMakerOfBadGames](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/amakerofbadgames/32/27156_2.png) [@AMakerOfBadGames](https://forum.makecode.com/u/AMakerOfBadGames)\
**Post date:** [December 17, 2024, 3:39am UTC](https://forum.makecode.com/t/how-to-stop-music-that-is-playing/32514/5 "2024-12-17T03:39:53Z")

</div>

glad to help
