Keep your Mac running with the lid closed so your AI coding sessions never die
No AI needed

Every step written out. No terminal experience needed. Pick your setup.
A tiny macOS menu-bar app that keeps your Mac running even with the lid closed — so coding agents (Claude Code, Codex, etc.) keep working while you move around.
Open source under the MIT License. Lidless is by Nghia Luong; this fork is maintained for publik and ships its own signed, notarized builds.
"I installed Lidless and the menu never opens." On a MacBook with a crowded menu bar, macOS puts the newest status item leftmost — which on notched MacBooks is behind the camera housing. The icon exists (accessibility can press it) but no click can reach it, and the first-run Welcome window opened behind whatever you had in front, so the app looked dead. Reproduced on a fresh 0.1.3 install with 12 other menu-bar items: the Lidless item sat at x 754–790 on a bar whose notch spans x 663–848.
MenuBarIconMonitor, pure geometry in MenuBarIconVisibility) and says so —
at the end of onboarding, in Settings, and inside the menu itself.Everything else — the root helper, watchdog, safety guards, timer, Sparkle — is
upstream Lidless, unchanged. Bundle id is com.publikhq.lidless (helper
com.publikhq.lidless.helper), signed with publik's Developer ID, updates from
this repo's own appcast.
SMAppService) so toggling never asks for a password.macOS sleeps when you close the lid. The reliable way to override that on Apple Silicon
is the SleepDisabled flag in IOPMrootDomain (what sudo pmset -a disablesleep 1 sets).
caffeinate does not prevent lid-close sleep — only this flag does.
The app talks to a root helper over XPC; the helper flips the flag with no admin prompt and runs a heartbeat watchdog. If the app stops checking in (>90s), the helper restores sleep.
Lidless — SwiftUI MenuBarExtra app (macOS 13+), not sandboxed, LSUIElement.LidlessHelper — root LaunchDaemon, registered via SMAppService, serves LidlessHelperProtocol over XPC. Embedded at Contents/MacOS/LidlessHelper with its plist in Contents/Library/LaunchDaemons/.Sources/Shared — pure, unit-tested logic: pmset parsers, watchdog, safety evaluator, settings.The app icon and the menu-bar glyphs are committed assets under
Resources/Assets.xcassets/ (AppIcon.appiconset plus the MenubarLaptop /
MenubarLaptopActive template imagesets that mark keep-awake off / on).
scripts/make_iconset.sh is kept as a helper for regenerating an icon set from a
single master if you want to swap the artwork:
bash scripts/make_iconset.sh # renders icon + emits Assets.xcassets/AppIcon.appiconset
Signed + notarized DMG plus the EdDSA-signed Sparkle appcast (needs a Developer ID cert, a notarytool keychain profile, and the Sparkle signing key in the keychain):
./scripts/release.sh # archive → export → notarize → staple → DMG → appcast → publish
Publishes the DMG to a GitHub Release and writes the feed to docs/appcast.xml
(served at the SUFeedURL in project.yml).
scripts/lidless.sh). ✅release.sh. ✅Running with the lid closed under heavy load can heat the machine and drain the battery. Keep it plugged in and ventilated. The safety guards auto-pause on heat / low battery, and a reboot always resets the underlying flag.
To report a security issue, see SECURITY.md.
Lidless is free and open source. If it saves you some hassle, you can buy me a coffee on Ko-fi ☕ — completely optional, and much appreciated.
MIT © 2026 Nghia Luong. Fork changes © 2026 publik, same license.