> ## Documentation Index
> Fetch the complete documentation index at: https://docs.servflow.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Installation

> Install ServFlow Pro, start the server, and create your first account

ServFlow is an agent builder: you define AI agents and the workflows they run, and a Go engine serves them. This guide installs the `servflow-pro` binary, starts an instance, and walks through the first-run account setup.

<Tip>
  Setting up a local environment with tracing and debugging? See [Local Environment Setup](/development).
</Tip>

## Prerequisites

* A terminal
* One of: Docker, Homebrew, npm, or Go — depending on the method you pick

## Quick start

```bash theme={null}
# Homebrew (macOS/Linux)
brew install Servflow/servflow/servflow-pro
servflow-pro start --config config.toml --dashboard

# Or Docker
docker run -p 8080:8080 servflow/servflow-pro
```

Then open **`http://localhost:8080/dashboard`** and create your account.

<Note>
  One port serves everything. The engine owns the root path, and `--dashboard` mounts the builder UI under `/dashboard` on that same port. Earlier versions used a separate port for the dashboard; they no longer do.
</Note>

## Installation methods

### Homebrew (macOS / Linux)

```bash theme={null}
brew install Servflow/servflow/servflow-pro
servflow-pro --version
```

### npm

```bash theme={null}
npm install -g servflow-pro
servflow-pro --version
```

### Docker

```bash theme={null}
docker pull servflow/servflow-pro:latest
```

Run with default configuration:

```bash theme={null}
docker run -p 8080:8080 servflow/servflow-pro
```

Run with a custom configuration and persistent storage:

```bash theme={null}
docker run -d \
  --name servflow-pro \
  -p 8080:8080 \
  -v $(pwd)/config.toml:/data/config.toml \
  -v $(pwd)/configs:/data/configs \
  -v $(pwd)/data:/data \
  servflow/servflow-pro
```

This exposes port **8080** for the engine, the API, and the dashboard, and mounts your configuration and data directories so agents survive restarts.

### Binary downloads

Download pre-built binaries from the [Releases](https://github.com/Servflow/servflow-pro/releases) page. Available for **Linux** (x86\_64, arm64) and **macOS** (x86\_64, arm64).

```bash theme={null}
tar -xzf servflow-pro_Linux_x86_64.tar.gz
chmod +x servflow-pro
./servflow-pro start --config config.toml --dashboard
```

### From source

```bash theme={null}
git clone https://github.com/Servflow/servflow-pro.git
cd servflow-pro
go build -o servflow-pro
./servflow-pro start --config config.toml --dashboard
```

<Note>
  Building from source requires Go 1.21 or later.
</Note>

## Create a configuration file

ServFlow reads a TOML file. Only `server.config_folder` is required:

```toml theme={null}
[server]
port = "8080"
config_folder = "./configs"
env = "production"

[sqlite]
path = "./data/servflow.db"
master_key = "your-secure-master-key"
```

<Warning>
  Never commit `master_key` to version control. Set it with the `SERVFLOW_SQLITE_MASTER_KEY` environment variable in production.
</Warning>

SQLite stores agents, workflow configs, secrets, integrations, and user accounts. Running without it falls back to file-based storage and disables secrets management, OAuth integrations, and the account system.

See the [Configuration Reference](/references/configuration) for every option.

## Start the server

```bash theme={null}
servflow-pro start --config config.toml --dashboard
```

| Flag               | Description                                                                        |
| ------------------ | ---------------------------------------------------------------------------------- |
| `--config`, `-c`   | Path to the TOML configuration file. Defaults to `~/.servflow/config.toml`         |
| `--dashboard`      | Mount the visual builder under `/dashboard`                                        |
| `--import-configs` | Import workflow configs from the config folder into SQLite. Requires `--dashboard` |

Without `--dashboard`, only the engine and API run — see [Running ServFlow](/running-modes).

## First run: create your account

The dashboard is gated by default (`authentication.mode = "local"`). On a fresh instance with no accounts yet:

<Steps>
  <Step title="Open the dashboard">
    Navigate to `http://localhost:8080/dashboard`.
  </Step>

  <Step title="Complete setup">
    A first-run setup wizard collects instance settings — your workspaces directory and whether to enable tracing. These are written to your `config.toml`.

    <Note>
      Setup settings are read once at startup, so ServFlow asks you to **restart the server** after saving them.
    </Note>
  </Step>

  <Step title="Create the first account">
    Register with an email and a password of at least **8 characters**. The first account is created without authentication to bootstrap the instance; afterwards, creating more accounts requires being signed in.
  </Step>

  <Step title="Sign in">
    Use those credentials on the sign-in screen. Sessions are opaque tokens stored in the database, so they survive restarts.
  </Step>
</Steps>

<Warning>
  Setup and first-account registration are only available while **no account exists**. Once one does, both are closed off.
</Warning>

To disable the gate entirely on a trusted local machine, set `mode = "none"`:

```toml theme={null}
[authentication]
mode = "none"
```

## Verify the installation

With the server running, create an agent and its first workflow in the dashboard, or check the CLI can reach your store:

```bash theme={null}
servflow-pro resource config list --config config.toml
```

## Next steps

<CardGroup cols={2}>
  <Card title="Quickstart" icon="rocket" href="/quickstart">
    Deploy your first API with the dashboard or declaratively.
  </Card>

  <Card title="Configuration Reference" icon="gear" href="/references/configuration">
    Every TOML option and environment variable.
  </Card>

  <Card title="Running ServFlow" icon="server" href="/running-modes">
    What the server serves, and how to deploy it.
  </Card>

  <Card title="Secrets Management" icon="key" href="/references/secrets">
    Store API keys and credentials securely.
  </Card>
</CardGroup>
