Insomnia is a menu bar utility and CLI that prevents your Mac from sleeping. Timed sessions, app-watching, recurring schedules. No fuss.
Toggle caffeination from the menu bar. Pick a duration, set a time, or leave it running indefinitely.
Caffeinate for 15 minutes, 2 hours, or any custom duration. Set an end time and forget about it.
Keep your Mac awake while a specific app is running. Close the app, caffeination stops.
Caffeinate every weekday from 9 to 5. Set rules once and they run automatically.
Everything the GUI does, from the terminal. Pipe into scripts, run from SSH, automate your workflow.
Optionally keep the display on too. Useful for presentations and long-running demos.
The CLI works standalone or talks to the GUI over a Unix socket when both are running.
brew install --cask gordonbeeming/tap/insomnia
Use the fully qualified tap name to avoid conflicts with the Insomnia API client.
Requires macOS 14 or later. Apple Silicon.