How to Prevent a MacBook From Sleeping When Lid Is Closed

You can keep your MacBook awake and even use an external monitor

What to Know

  • Navigate to System Preferences > Battery > Energy Saver > Power Adapter, and move the slider to Never.
  • After adjusting the Energy Saver settings, connect your MacBook to a charger and an external monitor.
  • The only way to keep a MacBook awake with the lid closed without connecting to a monitor is to use a third-party app.

This article explains how to prevent your MacBook from sleeping when the lid is closed.

Can You Stop a MacBook From Sleeping When You Close the Lid?

You can stop a MacBook from sleeping when you close the lid, and you can even use a MacBook that's closed if you connect a monitor, keyboard, and mouse. If you like to use your MacBook with an external monitor, but you don't have room on your desk for both the monitor and your MacBook, then closing it and storing it in a vertical stand while it's in use is a great solution.

How Do I Keep My MacBook On When I Close the Lid?

Your MacBook is designed to sleep whenever you close the lid as the default setting. This feature saves power when the MacBook is plugged in and preserves battery life when it isn't. The problem is if you want to close your MacBook and use it with an external monitor, you'll run into a situation where it sleeps instead. If you're going to keep using your MacBook with the lid closed, you'll need to change a few settings.

Here's how to keep your MacBook on when you close the lid:

You will also need to connect a keyboard to your MacBook and either a mouse or trackpad if you want to keep using it while it’s closed.

  1. Click the Apple icon in the upper left corner.

    The Apple icon highlighted on a Mac.
  2. Click System Preferences.

    System Preferences highlighted on a Mac.
  3. Click Battery.

    Battery highlighted in MacBook System Preferences.
  4. Click Power Adapter.

    Power Adapter highlighted in MacBook battery settings.
  5. Click the slider and move it to Never.

    Power Adapter highlighted in MacBook battery settings.
  6. Click the Prevent computer from sleeping automatically when the display is off check box.

    The prevent computer from sleeping checkbox highlighted in MacBook battery settings.
  7. Plug your MacBook into power.

  8. Connect your MacBook to an external monitor using an adapter if necessary.

  9. You can now close your MacBook without the display turning off.

If you want to use your MacBook in this configuration permanently, you can use the Mac sleep scheduler to have it sleep and night and wake up in the morning automatically.

Why Does My MacBook Sleep When I Close the Lid?

Your MacBook sleeps when you close the lid for a couple of different reasons, depending on whether it’s plugged in or not at the time. When it’s plugged in, it sleeps to help conserve energy and also allow it to charge more quickly, as it uses much less power while asleep. When running on battery power, it sleeps when you close the lid to conserve battery power. Since you typically don’t need to use your MacBook when the lid is closed, the default setting is for the display to turn off and the MacBook to sleep whenever the lid is closed.

The most common reason to want to keep a MacBook from sleeping when the lid is closed is if you're going to use it with an external monitor and keyboard. Apple makes that reasonably easy if you follow the instructions provided in the previous section.

Can You Keep a MacBook From Sleeping With the Lid Closed Without a Monitor?

Apple only provides you with one way to keep your MacBook from sleeping with the lid closed, and that’s to tweak the energy-saver settings, connect the battery charger, and plug in an external monitor.

If you want to keep your MacBook from sleeping without plugging in an external monitor, you need to install a third-party app. There is no option in the battery or energy saver settings that allows a MacBook to remain awake with the lid closed if an external monitor isn’t plugged in.

FAQ
  • How do I prevent a MacBook from sleeping when plugged in?

    Select System Preferences > Battery or Energy Saver > Power Adapter Turn display off after. Move the slider to Never and select Prevent computer from sleeping automatically when the display is off to keep your Mac from sleeping.

  • How do I prevent my MacBook from sleeping on battery power?

    If you don't want your MacBook to go into sleep mode after a certain amount of time on battery power, turn off this setting. Go to System Preferences > Battery or Energy Saver > Battery > Turn display off after > and move the toggle to the right to Never.

  • Why is my MacBook not sleeping when the lid is closed?

    Ensure the setting for turning off the display is active. Go to System Preferences > Battery or Energy Saver > Turn display off after. From Power Adapter, disable Wake for network access if this setting is on. Also, check Bluetooth wake settings; go to System Preferences > Bluetooth > Advanced > and uncheck Allow Bluetooth devices to wake this computer.

Was this page helpful?