Free & Open Source ยท Windows

Keep your PC awake
when it matters

Insomnia prevents Windows from sleeping โ€” automatically when AI coding tools are working, when specific apps are running, or manually on demand. No more broken sessions.

โ†“ Download for Windows View on GitHub
Insomnia app screenshot

You're running Claude Code or Aider on a long task. You step away. Your PC falls asleep, kills the process, and you come back to a broken session and lost work. Setting your sleep timeout to "Never" works โ€” but then your PC never sleeps when you actually want it to.

Insomnia fixes this. It stays awake only while something needs it, then gets out of the way.

Features

Smart, not blunt

โœจ

Hook-based AI integration

For Claude Code, Insomnia hooks directly into the event system โ€” awake while Claude is working, asleep the moment it stops. Precise to the second.

๐Ÿ“‹

App watching

Add any app as a trigger. Insomnia auto-discovers every installed app on your system. When it's running, you stay awake. When it closes, you don't.

๐Ÿ”˜

Manual toggle

Need to stay awake right now? One switch. No timers, no fuss. Toggle it off when you're done.

๐Ÿฆ‰

Lives in the tray

A purple owl means awake. A grey owl means inactive. The hover tooltip tells you exactly why. Close the window โ€” it keeps running.

โšก

Zero bloat

Plain HTML, CSS, and JS. No React. No bundler. Zero external runtime dependencies. Installs in seconds and uses almost no resources.

๐Ÿ”’

Local and private

Nothing leaves your machine. No telemetry, no accounts, no cloud. Settings are stored locally and that's it.

Integrations

Built for AI-assisted coding

Tool Type How it works
โœจ Claude Code Smart Hook-based โ€” awake only while Claude is actively running tools. Idle = asleep.
โœ๏ธ Cursor Process Awake while Cursor is open.
๐Ÿค– Aider Process Awake while Aider is running.
๐Ÿ’ป OpenAI Codex CLI Process Awake while Codex CLI is running.
๐Ÿง  Ollama Process Awake during local model inference.
Install

Get started in 30 seconds

Download the installer and run it. Or use a package manager:

# winget winget install StanleyProjects.Insomnia
# Scoop scoop bucket add stanley-projects https://github.com/stanley-projects/scoop-stanley
scoop install stanley-projects/insomnia
โ†“ Download Installer (.exe)

Windows 10/11 ยท Free ยท Open Source (MIT)