If your YouTube yoga stream stops when you close your laptop, the likely cause is that the laptop goes to sleep. On Windows, you can check and change the action assigned to closing the lid; on a Mac, the available behaviour depends on the setup, so do not assume the Windows instructions apply.
Start by confirming what the laptop does when you close the lid, then change one setting at a time and test it before relying on a long session. A setting that keeps the computer awake is not a promise that every laptop, player, network or YouTube broadcast will keep running unattended.
Check whether closing the lid triggers sleep
A video playing in a browser does not necessarily keep the computer awake. Lid-close behaviour is a power-management decision made by the operating system and, on some laptops, influenced by manufacturer settings. If that action puts the computer to sleep, the browser and the software sending your live broadcast may pause or lose their connection.
First establish what has actually stopped. Is the YouTube viewer showing a frozen picture or a disconnected live stream, or does the laptop merely turn off its built-in display while audio continues? If you are playing a yoga video for yourself, the distinction is between the screen going dark and playback stopping. If you are broadcasting a yoga session to YouTube Live, there is an additional distinction: a local preview can stop while the broadcast itself remains active, or the broadcast can disconnect even though the laptop appears awake.
Before changing settings, run a short, supervised check. Keep the laptop plugged in if practical, play the same video or run the same streaming setup you intend to use, and note whether audio continues, whether the screen goes dark, and whether a viewer on another device still sees the live stream. Do not leave a session unattended as your first test. If the behaviour changes depending on whether the charger is connected, record that; Windows lets you select separate lid actions for battery and plugged-in use.
Also check that closing the lid is the event that causes the interruption. A stream can stop because of a Wi-Fi drop, a browser or streaming application error, a low battery, or an issue at the YouTube end. If the laptop stays awake but the live broadcast ends, lid settings may not be the cause. The troubleshooting distinction in how to tell whether YouTube or your streaming setup caused an outage can help you separate a local power issue from a connection or service problem.
Change the Windows lid action for each power state
On many Windows laptops, the lid action is configured in Control Panel. Microsoft’s instructions are to open Control Panel, go to System and Security > Power Options, and select Choose what closing the lid does. You will see separate choices for On battery and Plugged in. The exact choices shown can depend on the PC and its manufacturer, so a missing option is not evidence that your device is broken.
For playback to continue with the lid shut, choose an action that does not put the laptop to sleep. Read each row carefully: selecting the desired action for Plugged in does not necessarily change On battery, or the other way round. If you want the video to continue only while connected to power, set the plugged-in action accordingly and leave the battery behaviour as a separate decision. That can be a sensible trade-off if you do not want a closed laptop to continue consuming battery when the charger is removed.
Use Microsoft’s current instructions for lid-close and other power actions if the labels differ on your version of Windows. The control is not the same thing as the screen timeout. Turning off the display after a period of inactivity does not, by itself, tell Windows what to do when you physically close the lid.
If Choose what closing the lid does is missing, or its choices are unavailable, note your laptop model and Windows version before trying workarounds. Microsoft says available power options may depend on the PC and manufacturer. Check the laptop maker’s documentation for that model rather than changing an unrelated advanced setting based on instructions for a different computer.
Verify the selected power states and save
Before leaving the Control Panel page, inspect both columns again. Decide what you want to happen in each case, choose the lid action that does not sleep for the power state you need, and use Save changes if the page presents that control. If you expect to run the yoga stream with the charger connected, confirm the Plugged in row specifically. If you may unplug it, check On battery as well, while considering how long the workload might run and how much charge is available.
This setting answers one narrow question: what Windows should do when the lid closes under that power condition. It does not set the browser’s behaviour, guarantee that an application will continue playing, or prevent every kind of shutdown. A critical battery condition, system update, crash, network interruption or software-specific rule can still end playback. Keep the distinction in mind if you are broadcasting rather than simply watching a class.
Windows 11 also has screen and sleep timeout controls at Settings > System > Power & battery > Screen, sleep, & hibernate timeouts. These are useful when the laptop sleeps after being left idle with the lid open. They are separate from the lid-close action. Microsoft’s Windows 11 power settings guidance describes those timeout controls; changing them is not a substitute for checking what happens when the lid itself closes.
After saving, return to the page and confirm your choices were retained. If the machine is managed by a workplace or school, policy may limit which options you can change. If the setting reverts, remains unavailable, or does not match what happens in the test, avoid assuming that another Windows version’s instructions will apply. Look up the exact laptop model and operating-system version with the manufacturer’s official support material.
If you use a Mac, treat it as a separate route
The Windows Control Panel path does not apply to a Mac. Apple’s published closed-display instructions concern a Mac laptop connected to an external display: connect the Mac to power and use an external keyboard and mouse. That is a particular operating arrangement, not a universal fix for every Mac, every model, or audio-only playback with the built-in display closed. Apple’s external display guidance sets out that context and should be checked against your equipment.
Apple also documents a battery setting called Prevent automatic sleeping on power adapter when the display is off. Its guidance on unexpected Mac sleep and wake behaviour explains relevant settings and factors that can affect sleep. Do not treat that option alone as proof that a Mac will continue playing with its lid shut: settings and connected devices can affect the result, and the Mac’s behaviour may differ from a Windows laptop’s.
If your use case is a MacBook closed while showing the yoga video on an external monitor, follow Apple’s current setup instructions and check the compatibility of the display, keyboard and mouse you already have or plan to use. If your use case is simply closing the lid while listening, Apple’s external-display instructions do not establish that this will work. Confirm the behaviour for your model in Apple’s support documentation and test while present. Avoid installing a third-party utility as a first step when the expected behaviour and compatibility are unclear.
Test playback before relying on a closed lid
Once you have changed the relevant setting, test the actual arrangement you plan to use. Start the same browser tab, media player or live-streaming software, connect the same charger or use the same battery state, and close the lid for a short, supervised interval. Check playback on the laptop where possible, then check the YouTube viewer from another device if you are sending a live broadcast. Confirm that picture and sound continue and that the live stream has not disconnected.
Repeat the test under the other power condition only if you expect to use it. For example, a result with the charger connected does not tell you what will happen on battery if Windows has separate actions for the two states. Likewise, an open-lid test does not verify a closed-display Mac setup. Change one thing at a time and write down the result; otherwise, if the stream stops, you will not know whether the lid action, idle timeout, network or application changed the behaviour.
If the video stops, reopen the lid and check whether the computer woke from sleep, whether the application is still running, and what the YouTube viewer shows. A machine that wakes and resumes may have behaved differently from one whose broadcast ended. If the computer stayed awake but the stream dropped, investigate the app and connection rather than repeatedly changing lid settings. For a playlist-based broadcast, the advice in how to stream a playlist to YouTube Live using OBS in India is relevant to the separate streaming-software setup, not a replacement for power testing.
For a personal yoga class, you may only need to confirm that the video and audio continue. For a live class you are hosting, arrange for someone to monitor the viewer side during the test. Keep the laptop accessible so you can reopen it if playback falters. A successful short check is useful evidence about your setup, but it cannot guarantee that the same result will hold through a long session or after software and power conditions change.
Review heat, power and sleep behaviour
A closed laptop has less exposed surface than an open one, and some models may manage heat differently when shut. Check the laptop maker’s operating guidance before running it closed for extended periods, especially if it feels unusually warm, the fans become noisy, or performance changes. Do not place it on bedding or cover vents. The goal is not just to keep playback running but to avoid a setup that traps heat or leaves the computer in an unsuitable position.
Power use is another trade-off. A laptop that stays awake can consume charge even with its display off. If you rely on battery, a long session may end when the battery runs low; the lid setting cannot create extra capacity. For a planned extended session, use the manufacturer-approved power arrangement and verify that the relevant plugged-in behaviour works. If you want the display dark while the lid remains open, use the normal display controls rather than assuming that closing the lid is needed to switch off the screen.
Sleep, hibernate and shutdown are different states, and the names and available actions can vary by device. A timeout may put the computer to sleep after inactivity; a lid action may trigger a separate response; critical battery behaviour can apply independently. If the laptop sleeps unexpectedly, check both the lid setting and the idle timeouts, then review the manufacturer’s documentation. Do not disable every sleep or battery protection setting to solve a problem that has not been traced to that setting.
If you are broadcasting a pre-recorded yoga session around the clock, keeping a personal laptop awake is only one part of keeping the broadcast going. The streaming software, internet connection and YouTube broadcast still need to remain active. If the recurring problem is that a laptop must stay open and powered just to keep a file on air, a cloud-run approach can remove that specific dependence on the local computer: StreamNeo runs an uploaded video as a YouTube live stream without requiring your computer to remain on. It is YouTube-only, so it is not a route for other platforms, and it does not remove the need to check the video, channel and broadcast setup.
A local OBS setup may still suit you if you need live camera input, scene changes or direct control over the session; see the practical OBS settings for a 24/7 Tamil songs playlist stream for a different continuous-playback example. A recorded-file loop and a live yoga class are not interchangeable needs. Choose the method based on whether the content is a fixed file or a real-time session, then test the entire chain rather than treating the lid setting as the whole solution.
Before committing, compare the operating options on the pricing page. When the file and channel are ready, start free — 24-hour trial, no card.
FAQ
Will changing the Windows lid action keep every YouTube stream running?
No. It changes Windows’ response to closing the lid for the selected power state, but it cannot guarantee that a browser, streaming application, network connection or YouTube broadcast will continue. Test the specific video or broadcast you plan to use.
Why does my stream work while plugged in but stop on battery?
Windows can assign different lid actions for On battery and Plugged in, so check both rows in Control Panel. Battery-related power behaviour may also differ, and the available settings depend on the computer and manufacturer.
Can I use the Windows steps on a MacBook?
No. The Control Panel route is for Windows. Apple’s closed-display instructions describe a Mac connected to an external display with power and an external keyboard and mouse; check Apple’s guidance for your model and test your exact arrangement.
What should I do if the lid setting is missing or does not work?
Write down the laptop model and operating-system version, then consult the computer maker’s official documentation. Do not assume that a setting shown for another model or OS version will be available or behave the same way on yours.