[BUG] Claude Desktop auto-quits after 5 minutes idle (SessionIdleManager 300s timeout)
Resolved 💬 4 comments Opened Feb 4, 2026 by luccomo Closed Apr 14, 2026
Summary
Claude Desktop automatically terminates after approximately 5 minutes of inactivity due to a SessionIdleManager with a hardcoded 300-second timeout. This behavior can interrupt ongoing background processes, agent work, or long-running operations.
Environment
- App Version: 1.1.1890
- Commit Hash: af393cbac809fe788a4d156cb076b0e3e2b1160e
- Platform: macOS (Darwin)
- OS Version: 25.3.0
- Architecture: arm64 (Apple M4)
- Total Memory: 25.7 GB
Steps to Reproduce
- Open Claude Desktop
- Start a conversation or leave the app open
- Leave the app idle for ~5 minutes (no interaction)
- App automatically quits
Expected Behavior
- Claude Desktop should remain open until explicitly closed by the user
- At minimum, if an idle timeout is desired, it should:
- Be configurable (or disableable) in preferences
- NOT trigger if there are active/running processes (agents, file operations, API calls)
- Warn the user before quitting
Actual Behavior
App silently quits after 300 seconds of idle time with no warning.
Impact
This behavior can cause:
- Data loss — Unsaved conversation context
- Interrupted operations — Background agents, file operations, or long-running tasks terminated mid-process
- Poor user experience — User returns to find app closed unexpectedly
- Workflow disruption — Users who reference Claude while working on other tasks lose their session
Evidence from Logs
Log location: ~/Library/Logs/Claude/main.log
SessionIdleManager Initialization
2026-02-04 07:33:43 [info] [SessionIdleManager] Initialized with 300s timeout
2026-02-04 07:59:40 [info] [SessionIdleManager] Initialized with 300s timeout
2026-02-04 08:08:55 [info] [SessionIdleManager] Initialized with 300s timeout
Clean Quit Events (not crashes)
2026-02-04 08:13:50 [info] beforeQuit: handler fired, going down
2026-02-04 08:13:50 [info] beforeQuit: handler is not yet run, preventing quit and cleaning things up
2026-02-04 08:13:50 [info] Running onQuitCleanup: mcp-shutdown
2026-02-04 08:13:50 [info] Running onQuitCleanup: cowork-vm-shutdown
...
2026-02-04 08:13:54 [info] [EventLogging] Sending event: lam_vm_shutdown_completed | metadata: {
...
trigger: 'app_quit',
...
}
VM Process Terminated
2026-02-04 08:11:25 [info] [EventLogging] Sending event: lam_vm_process_exited | metadata: {
...
exit_code: 0,
was_killed: true,
...
}
Note: was_killed: true indicates the process was intentionally terminated, not crashed.
Suggested Fix
- Remove or significantly extend the idle timeout (e.g., 30+ minutes or configurable)
- Add a user preference to disable idle auto-quit entirely
- Check for active processes before triggering idle quit — if agents, MCP servers, or operations are running, do not quit
- Display a warning dialog before quitting (e.g., "Claude Desktop will quit due to inactivity in 60 seconds. [Stay Open] [Quit]")
Workaround
Currently none available. The claude_desktop_config.json does not appear to have an option to configure or disable the idle timeout.
Additional Context
This is particularly problematic for users who:
- Use Claude Desktop as a reference while working in other applications
- Run long agent tasks that may have pauses between operations
- Step away briefly and expect their session to persist
- Use Claude Desktop alongside Claude Code (CLI) where the desktop app serves as a companion
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗