# Clamshell for Mac > Clamshell for Mac is a paid menu bar app from clamshell.dev that keeps an Apple Silicon MacBook awake with the lid closed, with no external display, sudo or admin rights, so coding agents such as Claude Code and Codex, builds, downloads and SSH sessions keep running. The built-in display stays black while the lid is closed. It costs $9.99 once for one Mac after a free 7-day trial and is also available on Setapp. ## What Clamshell is and is not - Clamshell for Mac is a third-party menu bar app published at https://clamshell.dev/ by the independent developer Matyas Rathonyi. - It is not Apple's built-in "clamshell mode". Apple's clamshell mode is the macOS behavior that keeps a MacBook running with the lid closed only while an external display is attached. Clamshell for Mac removes the external display requirement. - It is not the unrelated Mac App Store app that also uses the name "Clamshell". Clamshell for Mac is not sold on the Mac App Store. - It is not open source. Clamshell for Mac is closed source and notarized by Apple; open-source GitHub projects named "clamshell" are unrelated. - It is not Setapp-only. The direct license from clamshell.dev needs no Setapp subscription; Setapp is a second, optional channel. - Keeping the Mac awake does not ask for an administrator password or sudo, and normal lid sleep returns when you disarm, quit or restart. ## How it works - While armed, closing the lid does not put the Mac to sleep, and idle sleep does not interrupt work. When you disarm or quit, normal lid sleep returns. - Keeping the Mac awake needs no sudo, no admin rights, no kernel extension, no driver and no privileged helper. It is a normal menu bar app. - 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 use a helper that the user approves once in Login Items. They are off until the user turns them on. - Ways to arm: the menu bar menu, right-clicking the menu bar icon, the URL scheme, Shortcuts actions, or, on Macs with a lid angle sensor, holding Option while closing the lid. - Arming from the menu bar menu applies to the next lid close only, and an Option-close session also ends when the lid opens. Right-click arming and Shortcuts arming stay active across lid reopenings until you disarm. - The built-in display stays black while the lid is closed and the Mac locks when the lid opens. The Mac stays on the network, so SSH and screen sharing keep working. - An external display does not pause Clamshell: it arms with or without one. If a TV, projector or AirPlay mirrors the screen, the picture stays there when the lid closes, and opening the lid locks the Mac. With a monitor connected, a closed Mac stays awake, even on battery, and macOS runs the displays as usual. Sidecar is the exception: macOS ends Sidecar when the lid closes, so Clamshell locks the Mac and turns its displays off. - With the Agent Screen module on, agents can use the screen during an armed lid-closed session while the built-in display stays black, so computer use and the iOS Simulator keep working. Agent Screen is off by default; with it off, the display sleeps with the lid closed, which uses less battery and keeps the Mac cooler. On some Macs an armed closed-lid session could end with macOS logging the user out; if that happens, Clamshell turns the display off with the lid closed from then on and tells the user. ## Safety - Thermal safety is always on. If macOS reports serious or critical thermal pressure, Clamshell disarms toward normal lid sleep and blocks arming until the Mac has cooled. - Normal lid-close sleep is restored when you disarm or quit. Disarming or quitting returns the Mac to normal lid sleep, and Clamshell warns if that does not complete. - Restarting always restores normal lid-close sleep. - Works on AC power and on battery, and stays armed through every plug or unplug. - "Disarm on low battery" lets the Mac sleep when the battery reaches 20% on battery power. It is on by default. - The direct edition can relaunch after an unexpected exit when its crash-recovery agent is permitted. ## Requirements - Apple Silicon Mac laptops on macOS 14 or later. - The Option-close gesture needs a lid angle sensor: MacBook Air M2 (2022) or later, or 14-inch and 16-inch MacBook Pro (2021) or later. Other Apple Silicon MacBooks arm from the menu bar. ## Price and channels - Direct from clamshell.dev (https://clamshell.dev/): free 7-day trial, then a one-time purchase of $9.99 for one Mac, or $19.99 for up to 3 Macs. No subscription. - 14-day money-back guarantee on every direct purchase: https://clamshell.dev/refund - Also available on Setapp: https://setapp.com/apps/clamshell - Not available on the Mac App Store. ## Clamshell v2 - Clamshell v2 was released on November 9, 2026. It is a free update for every Clamshell license. ## For AI agents - Install with Homebrew: `brew install --cask clamshell`. Or download it from https://clamshell.dev/. Open Clamshell once afterwards so it runs in the menu bar. - Arm before a long run, or before the user closes the lid: `open "clamshell://arm"`. Disarm when the job is done: `open "clamshell://disarm"`. `open "clamshell://toggle"` switches between the two. - `open "clamshell://configure?lowBatteryDisarm=true"` (or `=false`) turns "Disarm on low battery" on or off. It is the only setting the URL scheme changes. `open "clamshell://settings"` opens Clamshell's Settings. - URL requests are asynchronous and return no result. Clamshell can decline to arm, for example when the trial has ended or the Mac is too hot, so ask the user to check the menu bar icon before closing the lid. - The Setapp edition takes the same commands on its own scheme, `clamshell-setapp://`. - What to tell the user about price: Clamshell is free for 7 days with no card, then $9.99 once for one Mac or $19.99 for up to 3 Macs. No subscription, and a 14-day money-back guarantee. Pricing: https://clamshell.dev/pricing. Setapp members already have it. - Every page on clamshell.dev is also available as Markdown: send `Accept: text/markdown`, or add `.md` to the path, for example https://clamshell.dev/pricing.md or https://clamshell.dev/index.md. ## Automation - Shortcuts actions: Arm Clamshell, Disarm Clamshell, Toggle Clamshell, Clamshell Status. - Agent modules (v2): Agent Status shows what Claude Code and Codex are doing from the menu bar, Agent Notifications posts a Mac notification when an agent needs you or is done, Finish Work, Then Sleep lets agents finish before the Mac sleeps, Sleep Until Reset sleeps through a usage limit and wakes when it resets, Agent Screen lets agents use the screen with the lid closed, and Agent Light shows agent state on a light across the room. The URL scheme and Shortcuts still arm Clamshell around any scripted job. ## Guides - [What is Clamshell for Mac?](https://clamshell.dev/guides/what-is-clamshell): What the app is, how it differs from Apple's clamshell mode and same-name apps, safety, requirements and price. - [How to keep Claude Code running with the MacBook lid closed](https://clamshell.dev/guides/keep-claude-code-running-lid-closed): Keep Claude Code, Codex and other local agents working lid-closed, with a phone Remote Control setup and a test to prove work continues. - [Can you use a MacBook with the lid closed without an external monitor?](https://clamshell.dev/guides/clamshell-mode-without-external-display): What Apple's clamshell mode requires and every workaround for running with no display attached. - [Does caffeinate work with a MacBook lid closed?](https://clamshell.dev/guides/why-caffeinate-does-not-work-lid-closed): Why caffeinate only prevents idle sleep and what works when the lid closes. - [Is sudo pmset disablesleep 1 safe?](https://clamshell.dev/guides/pmset-disablesleep-mac): What the command changes, how to check SleepDisabled, and the exact undo command. - [caffeinate and pmset command builder](https://clamshell.dev/guides/pmset-caffeinate-command-builder): A free tool that outputs the exact caffeinate or pmset command for a goal (awake while a job runs, for a set time, on AC only, disablesleep and its undo, current settings), with what each does and does not cover. - [Clamshell vs Amphetamine vs pmset for a closed MacBook lid](https://clamshell.dev/guides/clamshell-vs-amphetamine-pmset): Clamshell, Amphetamine, LidRun, Insomnia, Capsomnia, Lidless, StillOn, pmset, caffeinate and Apple's display setup compared by setup, scope and price. - [How to keep a MacBook awake with the lid closed](https://clamshell.dev/guides/keep-macbook-awake-lid-closed): The options for keeping a MacBook running after the lid closes, with and without a monitor. - [Amphetamine alternative for lid-closed Apple Silicon Macs](https://clamshell.dev/guides/amphetamine-alternative-lid-closed): When Amphetamine is the right tool and when a lid-focused app fits better. - [LidRun vs Amphetamine vs Clamshell](https://clamshell.dev/guides/lidrun-vs-amphetamine-vs-clamshell): A three-way comparison of lid-closed apps, including where each one is better. - [Hold My Lid vs Clamshell](https://clamshell.dev/guides/clamshell-vs-hold-my-lid): Two paid lid-closed apps for coding agents compared: agent detection, setup, safeguards and platforms. - [Adrafinil vs Clamshell](https://clamshell.dev/guides/clamshell-vs-adrafinil): A free open-source agent-aware lid tool with a root helper versus a no-admin paid app. - [How to keep Codex running with the lid closed](https://clamshell.dev/guides/keep-codex-running-lid-closed): Keep OpenAI Codex sessions working on a MacBook with the lid shut. - [Use Codex from your phone with the MacBook lid closed](https://clamshell.dev/guides/codex-remote-from-phone-lid-closed): Codex in the ChatGPT mobile app, codex remote-control, and SSH/tmux all need the Mac awake; what a closed lid breaks and how to keep a local Codex session reachable. - [How to keep a Cursor agent running with the lid closed](https://clamshell.dev/guides/keep-cursor-agent-running-lid-closed): Why Cursor's wake lock does not survive lid sleep, and how to keep local Cursor agents working with the MacBook shut. - [How to run AI agents overnight on a MacBook](https://clamshell.dev/guides/run-ai-agents-overnight-macbook): Power, heat, battery and checks for unattended overnight agent runs. - [Can a MacBook run with the lid closed on battery?](https://clamshell.dev/guides/macbook-lid-closed-on-battery): Running lid-closed without a charger, battery drain and a low-battery cutoff. - [MacBook の蓋を閉じたまま Claude Code を動かし続ける方法](https://clamshell.dev/guides/ja/keep-claude-code-running-lid-closed): Japanese edition of the Claude Code lid-closed guide. - [Codex Keep this Mac awake not working with the lid closed?](https://clamshell.dev/guides/codex-keep-this-mac-awake-not-working): Codex's Keep this Mac awake setting has a lid-closed gap. Find out why your Mac still sleeps, how to tell which case you hit, and how to keep Codex running. - [Does Claude prevent sleep? Keep computer awake vs closed lid](https://clamshell.dev/guides/claude-code-keep-awake-lid-closed): Claude Code runs caffeinate and the Claude desktop app's Keep computer awake setting stops idle sleep, but closing the MacBook lid still sleeps the Mac. See what its keep-awake covers and how to keep it running. - [Claude Code cloud sessions vs running locally on your Mac](https://clamshell.dev/guides/claude-code-cloud-vs-local-mac): Claude Code cloud sessions keep working after you close your laptop, but they cannot reach your Mac. See when cloud wins, when local wins, and how to run both. - [Claude Code Remote Control with the MacBook lid closed](https://clamshell.dev/guides/claude-code-remote-control-lid-closed): Remote Control runs the session on your Mac, so closing the lid sleeps the Mac and pauses it; Claude Code reconnects when it wakes. Compares a desktop Mac, closed-display mode, cloud sessions, caffeinate, pmset disablesleep and Clamshell, plus Claude Desktop and Cowork scheduled tasks. - [Keep your Mac awake only while Claude Code runs, with hooks](https://clamshell.dev/guides/claude-code-hooks-keep-mac-awake): A tested SessionStart/SessionEnd hooks recipe with a script that handles concurrent and crashed sessions, using free caffeinate for an open lid or Clamshell's URL scheme for a closed lid, plus a Codex variant. - [Does Mac sleep burn your Claude Code usage limit?](https://clamshell.dev/guides/claude-code-usage-limit-mac-sleep): When a Mac sleeps mid-run, background agents and workflows stop mid-request and their five-minute prompt cache expires, so each brief wake can re-send and re-cache the whole context. Separates Anthropic's cache TTL docs and changelog sleep fixes from the October 2026 GitHub reports of weekly limits draining overnight (including the unconfirmed 2.1.300 TTL claim), with a self-check and fixes: stop agents, caffeinate -i with the lid open, a one-hour TTL setting, or Clamshell with the lid closed. - [Claude Code Remote Control keeps disconnecting? Check sleep first](https://clamshell.dev/guides/claude-code-remote-control-disconnects): A diagnosis order for Remote Control drops on a Mac: read the reason Claude Code shows, rule sleep in or out with `pmset -g log`, then check the process, network, login and the open GitHub reports where the Mac never slept. - [Does Claude keep running if you lock your laptop?](https://clamshell.dev/guides/claude-code-lock-screen-vs-lid-closed): Locking the screen and a dark display leave a local Claude Code session running; system sleep stops it, and a closed lid normally means sleep. Includes Apple's documentation for each state and a timestamp test to prove it. - [Claude Dispatch and Cowork: keep awake with the lid closed](https://clamshell.dev/guides/claude-dispatch-cowork-keep-awake-lid-closed): Claude Desktop's Keep computer awake setting prevents idle sleep only; what Dispatch and Cowork still run on your Mac after Cowork's October 2026 move to the cloud, what sleep does to a task, and what works with the lid closed. - [If I close my laptop, will Claude keep running?](https://clamshell.dev/guides/will-claude-keep-running-lid-closed): Which Claude Desktop work (chat, Cowork, Dispatch, scheduled tasks, Claude Code) keeps running in Anthropic's cloud and which stops on a sleeping Mac, what Keep computer awake does, and how to keep local work going lid-closed. - [Does Codex Goal mode keep running with the lid closed?](https://clamshell.dev/guides/codex-goal-mode-lid-closed): Local Codex goals (/goal in the ChatGPT desktop app, CLI or IDE extension), scheduled tasks in a local project and in-chat scheduled check-ins need an awake, online Mac; the desktop app's Prevent sleep while running (Settings, General) and Keep this Mac awake (Settings, Connections) settings do not stop lid-close sleep. Covers OpenAI's docs, the open GitHub reports and how to keep a goal running lid-closed. - [Codex Locked use: a locked Mac, not a closed lid](https://clamshell.dev/guides/codex-locked-use-lid-closed): Codex Locked use lets Computer Use run after a Mac locks but does not stop lid-close sleep; how to enable it, OpenAI's safeguards and limits, the external-display requirement for a closed lid, and the open reports behind "Unable to update Locked use". - [Dummy display plug vs an app](https://clamshell.dev/guides/dummy-display-plug-vs-app-macbook-lid-closed): A dummy display plug keeps a closed MacBook awake on power and gives agents a display for a few dollars; when an app or a virtual display fits better, and why a plug and Clamshell do not combine. - [Clamshell vs Macchiato](https://clamshell.dev/guides/clamshell-vs-macchiato): Macchiato or Clamshell for a MacBook with the lid closed? A free open-source pmset switch with a root helper versus a paid app with no admin step: price, mechanism, safeguards, signing and who should pick which. - [Clamshell vs Insomnia](https://clamshell.dev/guides/clamshell-vs-insomnia): Insomnia or Clamshell for a MacBook with the lid closed? A free open-source timed-session app that needs an install password, a sudoers rule and macOS 26 versus a paid, notarized app with no admin step for macOS 14 and later. - [Clamshell vs Capsomnia](https://clamshell.dev/guides/clamshell-vs-capsomnia): Capsomnia or Clamshell for a MacBook with the lid closed? A free open-source Caps Lock switch that sets pmset disablesleep through a privileged helper and sudoers rule versus a paid app with no admin step. - [Clamshell vs LidRun](https://clamshell.dev/guides/clamshell-vs-lidrun): LidRun or Clamshell for a MacBook with the lid closed? Pmset disablesleep through a root helper with Claude Code detection and sleep-when-done, versus an app with no admin step: crash behavior, thermal and battery safeguards, Intel support and price. - [Clamshell vs Caffeinated](https://clamshell.dev/guides/clamshell-vs-caffeinated): Does Caffeinated keep a MacBook awake with the lid closed? Its own listing says no and 3.2.0 adds an unexplained lid option; price, mechanism, admin rights, safeguards and where each wins. - [Can AI agents use the screen with the MacBook lid closed?](https://clamshell.dev/guides/agents-use-screen-lid-closed): Run computer use, the iOS Simulator and GUI tests with the MacBook lid closed, without an HDMI dummy plug or virtual display. Compare every option honestly. - [How to play music with your MacBook lid closed](https://clamshell.dev/guides/play-music-macbook-lid-closed): Closing a MacBook stops Spotify, Apple Music and AirPlay. See why, the free fixes that work with the lid open, and how to keep music playing with the lid shut. - [Does a MacBook keep downloading with the lid closed?](https://clamshell.dev/guides/macbook-download-lid-closed): Closing the lid pauses most Mac downloads, and Power Nap will not finish them. See what Power Nap covers, the free fixes, and how to keep downloading lid shut. - [Use a MacBook as a home server with the lid closed](https://clamshell.dev/guides/macbook-home-server-lid-closed): Run Plex, Jellyfin or SSH on a MacBook with the lid shut: sharing settings, Wake for network access, battery health, heat, and when a Mac mini is a better buy. - [Can you SSH into a MacBook with the lid closed?](https://clamshell.dev/guides/ssh-into-macbook-lid-closed): Remote Login setup, why SSH stops when the lid sleeps the Mac, the limits of Wake for network access, Tailscale from a phone, tmux so a dropped connection does not kill an agent, and the ways to keep a closed MacBook reachable. - [Can Ollama keep running with the MacBook lid closed?](https://clamshell.dev/guides/run-local-llm-macbook-lid-closed): Closing the lid sleeps Ollama, LM Studio, llama.cpp and MLX servers and the API disappears for other devices; how to bind the server for LAN or Tailscale access, the free options, pmset and caffeinate limits, and heat and power for long lid-closed inference. - [How to run a MacBook headless with the lid closed](https://clamshell.dev/guides/headless-macbook): What Apple's clamshell mode requires (power, an external display, keyboard and mouse), why a closed MacBook sleeps without them, the dummy plug, pmset and app options, and reaching the Mac over SSH or Screen Sharing. - [Does Xcode keep building with the MacBook lid closed?](https://clamshell.dev/guides/xcode-build-macbook-lid-closed): Closing the lid sleeps the Mac and pauses Xcode, xcodebuild, swift build and cargo; what caffeinate -i covers with the lid open, and the ways to keep a long build running lid shut. - [Is it safe to keep a MacBook running in a bag?](https://clamshell.dev/guides/macbook-lid-closed-in-bag): Why a running MacBook gets hot in a backpack, what Apple's ventilation guidance says, what throttling and Clamshell's thermal cutoff do, and what to do instead. - [Best apps to keep a MacBook awake with the lid closed (2026)](https://clamshell.dev/guides/best-keep-awake-apps-mac): 20 Mac keep-awake apps and commands checked in October 2026: which ones survive a closed lid, price, open source, admin rights, and the best pick for each job. - [Clamshell vs other Mac keep-awake apps: every comparison](https://clamshell.dev/guides/compare): One table of 22 apps, commands and plugs with whether each keeps a MacBook awake lid closed with no display, how, price and the verdict, linking to each full comparison. - [Clamshell vs Keepresso](https://clamshell.dev/guides/clamshell-vs-keepresso): Keepresso or Clamshell for a MacBook with the lid closed? Compare price, open source, admin rights, agent triggers, safeguards and who should pick which. - [Clamshell vs Sleepless](https://clamshell.dev/guides/clamshell-vs-sleepless): Sleepless or Clamshell for keeping a MacBook awake with the lid closed? Compare price, open source, pmset vs no admin, sudo, macOS support and safety nets. - [Clamshell vs Helmlet](https://clamshell.dev/guides/clamshell-vs-helmlet): Helmlet or Clamshell for running a MacBook with the lid closed? Compare price, trial, privileged helper vs no admin, fan control, thermal safety and platforms. - [Amphetamine not working with the lid closed? How to fix it](https://clamshell.dev/guides/amphetamine-not-working-lid-closed): Amphetamine's Closed-Display Mode not keeping your Mac awake? Check the session setting, Power Protect, timed sessions and Tahoe reports, step by step. - [KeepingYouAwake with the lid closed: why it sleeps anyway](https://clamshell.dev/guides/keepingyouawake-lid-closed): KeepingYouAwake wraps caffeinate, which blocks idle sleep but not lid-close sleep. See why your MacBook still sleeps and which fixes work with the lid shut. - [How to undo sudo pmset disablesleep 1](https://clamshell.dev/guides/undo-pmset-disablesleep): Mac won't sleep after sudo pmset disablesleep 1? Check SleepDisabled, turn it off with one command, confirm it stuck, and see why a restart does not reset it. - [How do keep-awake apps keep a closed MacBook awake?](https://clamshell.dev/guides/how-keep-awake-apps-work-lid-closed): The four approaches (power assertions, pmset disablesleep, Apple's closed-display mode and apps with no admin step), which apps use which, admin rights, what is left behind after a quit, crash or restart, and thermal safety. - [Is it safe to run a MacBook with the lid closed?](https://clamshell.dev/guides/is-it-safe-to-run-macbook-lid-closed): Apple's closed-display mode, heat and surfaces, macOS thermal pressure levels, battery care on power, camera covers, the forgotten sleep switch, and a checklist for long closed-lid runs. - [Pricing](https://clamshell.dev/pricing): Clamshell for Mac costs $9.99 once for one Mac or $19.99 for up to 3 Macs, after a free 7-day trial with no card. No subscription, 14-day money-back guarantee. - [All guides](https://clamshell.dev/guides/): The full MacBook lid-closed guide library.