For keeping a MacBook awake with the lid closed, pick Clamshell. It needs no admin rights or root helper, leaves nothing to undo, and runs on macOS 14 or later, where Adrafinil needs macOS 26. This page is written by the maker of Clamshell, and it says where Adrafinil is the better choice.
Clamshell for Mac keeps the Mac awake with the lid closed while armed. No sudo, no monitor. Free for 7 days, then $9.99 once.
Apple Silicon, macOS 14+. Notarized by Apple. 3.6 MB. Or install with Homebrew: brew install --cask clamshell. On your phone? Send the Mac download link to yourself.
pmset disablesleep through a root helper while an agent is working.Clamshell for Mac is a menu bar app for Apple Silicon MacBooks: you arm it, close the lid, and the Mac keeps running with the built-in display black. It needs no admin rights or helper, and runs on macOS 14 or later. Adrafinil is a free, MIT-licensed app that keeps a Mac awake only while AI agents are working: hooks in Claude Code, Codex, Cursor and others acquire and release a hold, and a privileged helper toggles pmset disablesleep.
Why Clamshell is the better pick
- No admin rights, no root helper. Adrafinil's standard install asks an administrator once to register a privileged helper that runs as root. Clamshell needs neither, so it also fits work Macs where you are not an administrator.
- Nothing to clean up.
pmset disablesleepis a system setting; Adrafinil's README says it must be cleared or it leaks, which is why its helper resets it on respawn. Clamshell restores normal lid sleep when you disarm or quit, and a restart does the same. - Runs on the macOS you have. Clamshell supports macOS 14 or later. Adrafinil requires macOS 26, or a community backport for macOS 15.
- Any job, not only hooked agents. Downloads, renders, builds or SSH sessions stay up as long as you keep it armed. Adrafinil holds sleep while an agent hook or process sniffer reports work.
- Battery and thermal safeguards. A low-battery disarm at 20%, on by default, and thermal safety that is always on and acts at serious pressure, not only critical.
pmset disablesleep, and registering that helper needs an administrator once.Skip the root helper. Try Clamshell free for 7 days with no payment details, then $9.99 once for one Mac. 14-day money-back guarantee.
Apple Silicon, macOS 14+. Notarized by Apple. 3.6 MB. Or install with Homebrew: brew install --cask clamshell.
Side-by-side comparison
Every Adrafinil cell comes from its own pages, checked October 2, 2026. "Not stated" means we could not find it on their official pages; it does not mean the feature is missing.
| Clamshell Recommended | Adrafinil | |
|---|---|---|
| Admin or helper | None. No sudo, admin rights, kernel extension, driver, or privileged helper. | Root helper. Admin rights once at first launch to register it. A non-admin install path covers the CLI only. |
| How closed-lid works | No admin rights. Keeps the Mac awake with the lid closed only while armed; normal lid sleep returns on disarm or quit. | Uses pmset. A privileged helper sets pmset disablesleep while a hold is live, per its README. It also suppresses idle sleep while held. |
| Restore behavior | Option-close and menu arming cover the next close; on lid open the Mac locks. Right-click and Shortcuts arming stay until disarmed. A restart restores normal lid sleep. | Sleeps normally once the last agent session releases. Locks on lid close. The helper resets disablesleep to 0 on respawn so a crash does not leave it on; manual fallback is sudo pmset -a disablesleep 0. |
| Platform | Apple Silicon MacBooks, macOS 14 or later. | Needs macOS 26 or later. A community fork backports to macOS 15. Chip support not stated. |
| Thermal safeguard | Always on. Serious or critical thermal pressure disarms toward normal lid sleep and blocks arming until cooled. | A thermal cutout force-releases the hold. |
| Battery safeguard | Low-battery disarm at 20% on battery, on by default. Stays armed through every plug or unplug. | Not stated. |
| Closed-lid support | Yes, with no external display. | Yes, with the lid fully closed. |
| Price | Paid, closed source. 7-day free trial, then $9.99 once for 1 Mac or $19.99 for 3 Macs. 14-day money-back guarantee. | Free. Open source under the MIT license. |
| Agent auto-detection | Optional modules. The core does not detect agents. Agent Status shows in the menu bar how many Claude Code, Codex, Grok, OpenCode and Kiro sessions are working or waiting on you, Agent Notifications tells you when one stops for your approval or a question or finishes longer work, and Finish Work, Then Sleep, chosen from the menu bar, keeps the closed Mac awake until they finish, then lets it sleep. Arm from scripts with clamshell://arm and clamshell://disarm, or Shortcuts actions. |
Yes. One-click hooks for Claude Code, Codex, Cursor, Gemini CLI, Aider, Hermes, OpenCode, Cline and Pi, plus optional process sniffing. |
| Availability | clamshell.dev and Setapp. Notarized by Apple. | Signed, notarized DMG from GitHub releases and an official Homebrew cask. |
| Source code | Closed source, paid: $9.99 once after a 7-day free trial. | Open source, MIT. |
For agent runs, the Clamshell wrapper calls open "clamshell://arm" before the run and open "clamshell://disarm" after. The Claude Code lid-closed guide has a complete script.
An animated MacBook with a coding agent deploying a website from its terminal. The Option key is held and the lid closes: the display goes black, but the Mac stays awake, so a dimmed copy of the terminal keeps working above the closed laptop while its front edge fills with light. When the deploy is done, a pointer shows how to lift the lid. Opening it wakes the Mac to its lock screen, which unlocks to the finished run: deployed, with the live address. The lid can then be opened and closed freely.
Frequently asked questions
Do I need an admin password for Clamshell?
No. Keeping the Mac awake with Clamshell needs no sudo, admin prompt or privileged helper, and nothing to approve; only the optional modules Low Power While Closed, Fan Boost, Agent Light, Sleep Until Reset, Sleep Means Sleep, Stay Off When Opened and Password After Close, off until you turn them on, ask for a one-time approval in Login Items. Adrafinil's standard install asks for admin rights once to register its privileged helper.
Does Clamshell leave anything behind?
No. Clamshell restores normal lid sleep when you disarm or quit, and a restart does the same. Adrafinil's README notes that pmset disablesleep must be cleared or it leaks, so its helper resets it on respawn.
Does Clamshell run on macOS 14 or 15?
Yes. Clamshell runs on macOS 14 or later on Apple Silicon MacBooks. Adrafinil requires macOS 26 or later, with a community backport for macOS 15.
Is there a free trial?
Yes. Clamshell is free for 7 days with no payment details, then $9.99 once for one Mac or $19.99 for three, with a 14-day money-back guarantee. Adrafinil is free and open source under the MIT license.
What is the difference between Adrafinil and Clamshell?
Adrafinil is a free, open-source app that holds sleep only while AI agents are working, using a root helper that sets pmset disablesleep. Clamshell for Mac is a paid menu bar app that keeps an Apple Silicon MacBook awake with the lid closed while armed, with no admin rights or helper.
Does Clamshell detect AI agents like Adrafinil does?
Not in its core. Adrafinil has hooks for agents such as Claude Code, Codex and Cursor. Clamshell keeps the Mac awake while armed, whatever is running. Its optional Agent Status, Agent Notifications and Finish Work, Then Sleep modules follow Claude Code, Codex, Grok, OpenCode and Kiro sessions with nothing set up in those tools, but they do not arm Clamshell by themselves; a wrapper script can arm it with clamshell://arm and disarm it with clamshell://disarm.
If you want a free, open-source tool with agent hooks and you run macOS 26 with admin rights, Adrafinil covers that.
Clamshell is the pick for a closed lid. No admin rights, no root helper, and a restart restores normal lid sleep. Free for 7 days, then $9.99 once.
Apple Silicon, macOS 14+. Notarized by Apple. 3.6 MB. Or install with Homebrew: brew install --cask clamshell.
Related guides
- How to keep a MacBook awake with the lid closed
- Clamshell vs LidRun vs Amphetamine
- Clamshell vs Hold My Lid
- Best apps to keep a MacBook awake with the lid closed
- What sudo pmset disablesleep 1 does and how to undo it
- Keep Claude Code running with the lid closed
Sources checked October 2, 2026: Adrafinil's homepage and GitHub README, rechecked October 5, 2026. Clamshell details come from its own documentation and changelog. Clamshell is the publisher of this comparison. Product names belong to their respective owners.