Skip to main content

Starting Mercury

Recommended: mercury up

The easiest way to run Mercury persistently. Installs the system service if needed, starts the daemon, and ensures it's running.

mercury up

If Mercury is already running, mercury up just confirms it and shows the PID. If the service isn't installed yet, it installs it first, then starts the daemon.

Start (background daemon)

mercury start

Starts Mercury as a background daemon by default. Telegram becomes your primary interface. Logs go to ~/.mercury/daemon.log. Stale PID files are auto-cleaned. Includes crash recovery with exponential backoff.

Foreground (interactive)

mercury start --foreground

Runs Mercury attached to your terminal with the Ink TUI interface. Press Ctrl+C to exit. The CLI supports chat, coding workspace mode, progress views, and interactive permission prompts. Shorthand: mercury start -f.

When running in background mode, you can stop it with:

mercury stop

Verbose logging

Add --verbose to any start command to see debug logs on stderr:

mercury start --verbose