---
title: Command line
description: Every admiral command.
section: Reference
order: 1
---

# Command line

The `admiral` command controls the engine from a terminal. The app and the CLI share one engine and one data directory.

## Commands

| Command | What it does |
| --- | --- |
| `admiral login` | Sign in to your account. |
| `admiral logout` | Sign out. |
| `admiral status` | Show the engine and account state. |
| `admiral update` | Update Admiral to the latest release. |
| `admiral headless` | Run the engine with no window. |
| `admiral daemon install` | Install the engine as a user service that starts at login. |
| `admiral daemon start` | Start the service. |
| `admiral daemon stop` | Stop the service. |
| `admiral daemon restart` | Restart the service. |
| `admiral daemon status` | Show the service state. |
| `admiral daemon uninstall` | Remove the service. |
| `admiral chat` | Drive sessions from scripts, with JSON output and typed exit codes. |

## Rules

- **Sign in and out only while the engine is stopped.** Close the Admiral app, run `admiral login` or `admiral logout`, then start the app.
- **A service-run engine has no sign-in prompt.** Run `admiral login` interactively first; the service picks up the session when it starts. See [Run a headless engine](../guides/run-a-headless-engine.md).
- **The daemon is a per-user service.** On macOS it uses launchd; on Linux it uses systemd user units. It starts when you log in to the machine, not at boot.

## The data directory

Admiral keeps its data, including sessions, under your home directory in `~/.admiral`. Delete nothing there while the engine runs.

## Next steps

- [Run a headless engine](../guides/run-a-headless-engine.md): the daemon in context.
- [Settings pages](settings.md): the in-app alternative to most of these commands.
