InsomniaX alternative

InsomniaX is gone.
Closed-lid mode isn't.

For years InsomniaX was the answer to “how do I keep my MacBook awake with the lid closed.” It hasn't been updated since 2014, its author stopped supporting it in 2017, and it never ran natively on Apple Silicon. Midnight Oil does the same job on a current Mac, without a kernel extension.

The short version

Don't install InsomniaX on a modern Mac: it's Intel-only, unsupported, and its loader had a published security flaw. Midnight Oil is free, keeps a MacBook awake with the lid closed through a signed helper, and puts normal sleep back the moment a session ends.

What InsomniaX did

InsomniaX was a free menu bar app by semaja2. Its headline feature was Disable Lid Sleep: close the MacBook and it kept running, at a time when Apple only allowed that with an external display attached. It also offered Disable Idle Sleep, timers, and later a hot key to sleep the display.

The lid trick worked by loading a kernel extension, Insomnia, into macOS itself. That was the norm for Mac utilities in 2010. It isn't any more.

Why it stopped working

No updates since 2014

Version 2.1.8, released in October 2014, was the last. In 2017 a security advisory showed that the loader InsomniaX shipped with could be used to load any kernel extension, and the author announced the app was no longer supported.

Intel only, kernel extension required

InsomniaX was built for Intel Macs. Since macOS Big Sur, third-party kernel extensions need explicit approval and a restart, and on Apple Silicon they need the Mac's security lowered in Recovery. That's a lot to give up for a keep-awake switch.

Midnight Oil vs InsomniaX

Midnight OilInsomniaX
PriceFreeFree
Last updated2026, actively maintainedOctober 2014
Apple SiliconYes, nativeNo
Closed-lid modeYes, through a signed helperYes, through a kernel extension
Sleep restored automaticallyYes, when the session endsNo, until you switch it back
Battery safetyEnds on low battery or unplug, lid alarmNo
Timed and until-a-time sessionsYesTimers only
Triggers and schedulesYesNo
A command for scripts and AI agentsYes, midnightoilNo
Source code publicYesPartly, the kernel extension

How Midnight Oil keeps a closed lid awake

A small helper, signed and notarized, that you approve once in System Settings › Login Items. It turns lid sleep off only while a closed-lid session runs, and turns it back on when the session ends, when the app quits, or if the app crashes. On battery, an alarm sounds when the lid closes, and sessions can end below a battery level you choose.

Switching

  1. Remove InsomniaX if it's still there. Quit it, drag it to the Trash, and check System Settings › General › Login Items for leftovers.
  2. Install Midnight Oil. brew install --cask coreyhaines31/tap/midnightoil, or the DMG from GitHub.
  3. Approve the closed-lid helper once. Settings › Closed Lid › Install, then allow it in Login Items.
  4. Start a session with “Stay awake with lid closed” checked. Close the lid. When the session ends, your MacBook sleeps normally again.

More on the options, with and without an app, in the clamshell mode guide.

Lid closed. Mac still working.

Free. No account, no subscription.

macOS 14 or later · Apple Silicon and Intel · brew install --cask coreyhaines31/tap/midnightoil