Run the local-only daemon
Use this path when you want a solo, open-source KB-1 vault on your own machine. Local-only mode does not require a KB-1 Cloud account. The daemon serves the web UI, local API, and local MCP endpoint from one localhost service.
Local-only mode does not include Cloud users, organizations, team presence, or Cloud MCP. Agents connect to the daemon from the same machine or from a private network you have deliberately trusted.
Connect self-hosted Cloud login when you want Cloud identity, organization membership, relay, presence, or team access while keeping the daemon on your machine. Relay also lets agents reach the vault without being colocated with the daemon.
What this sets up
Section titled “What this sets up”- A local KB-1 daemon on
127.0.0.1. - A filesystem-backed vault under
KB1_HOME. - A local web app at the daemon port.
- A local MCP endpoint at
/mcpfor agents on the same machine. - Markdown notes, binary attachments, vault management, and Git-backed, best-effort note history in the local UI.
Prerequisites
Section titled “Prerequisites”- A supported Node release: 20.19.x, 22.12+, or 24+.
pnpmthrough Corepack.- Git.
- A writable directory for daemon state.
- No process already using the daemon port you choose.
KB-1 Local is released under the Apache-2.0 license. Runtime names use KB-1
throughout: KB1_HOME, KB1_PORT, KB1_HOST, and kb1d.
Start KB-1 Local
Section titled “Start KB-1 Local”Clone the public source and install the locked dependencies:
git clone https://github.com/metatheoryinc/kb-1-daemon.gitcd kb-1-daemoncorepack enablecorepack installpnpm install --frozen-lockfileStart the daemon and development web UI from that checkout:
KB1_HOME="$PWD/.kb1-quickstart" KB1_PORT=7382 pnpm devExpected output includes:
KB-1 dev front door: http://127.0.0.1:7382Vite dev server: http://127.0.0.1:5173[daemon] kb1d listening on http://127.0.0.1:7382[daemon] KB1_HOME=<your checkout>/.kb1-quickstartOpen the app:
http://127.0.0.1:7382/On first boot, the daemon creates a starter vault named demo-vault.
Docker alternative
Section titled “Docker alternative”From the same checkout, you can build and run the production image instead of installing the Node dependencies. Keep the unauthenticated Local port bound to loopback:
docker build -f apps/daemon/Dockerfile -t kb-1-daemon .docker run --rm \ -p 127.0.0.1:7382:7382 \ -v kb1-home:/data/kb1 \ kb-1-daemonThe named kb1-home volume preserves the local vault across container
restarts. Open http://127.0.0.1:7382/ and use the same verification commands
below.
Verify the daemon
Section titled “Verify the daemon”In a second terminal:
curl http://127.0.0.1:7382/api/healthcurl http://127.0.0.1:7382/api/vaultscurl http://127.0.0.1:7382/api/vaults/demo-vault/treeThe health response should be shaped like:
{ "ok": true, "service": "kb1d", "status": { "serviceName": "kb1d", "kb1Home": "<your checkout>/.kb1-quickstart", "statusFile": "<your checkout>/.kb1-quickstart/daemon/status.json" }}The vault list should include the starter vault:
{ "ok": true, "vaults": [{ "id": "demo-vault", "displayName": "demo-vault" }] }The tree response should include Markdown files from the starter kit.
Create another local vault
Section titled “Create another local vault”curl -X POST http://127.0.0.1:7382/api/vaults \ -H 'content-type: application/json' \ -d '{"displayName":"Field Notes","slug":"field-notes"}'A successful response is 201:
{ "ok": true, "vault": { "id": "field-notes", "displayName": "Field Notes" } }The new vault is immediately available without restarting:
curl http://127.0.0.1:7382/api/vaults/field-notes/treeDone looks like
Section titled “Done looks like”curl /api/healthreturnsok: true.- The web app opens at the daemon port.
curl /api/vaultslists at least one vault.- Creating a note in the UI writes a Markdown file under
KB1_HOME/vaults/<vault-id>/. - Local agents can connect to
http://127.0.0.1:7382/mcp.