I have currently no power connection to my MacBook Air, but I have a Display connected. I want to close the lid and only work on my external display.

So I want to prevent my MacBook going to StandBy when I close the lid. When I have the power cable connected, it will just switch to the bigger screen. But when the connector isn't attached, it will go to sleep.

How to prevent going to StandBy if no power connector is attached? Any app or terminal command?

I am running OS X Yosemite on a MacBook Air mid-2011.


2 Answers 2


NoSleep prevents sleep when lid is closed.


there's an app called insomniax which can disable lid sleep for you, i was looking for the same thing as you but this is all i found..

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .