# Quickstart

In about ten minutes you'll have Hatch running, a note with a link and a chart in it, an agent that can read your notes, and a page published from them.

## Before you start

- Node 22 or newer, and pnpm 10 (`corepack enable` sets it up).
- An agent that speaks MCP, like Claude Code, Codex, Cursor or Claude Desktop, for step 4.

Hatch isn't in app stores yet, so you run it from the repo.

````steps
step: Run Hatch
Clone the repo and start the web app.

```sh
git clone https://github.com/alexwhitmore/hatchmd.git
cd hatchmd
pnpm install
pnpm dev
```

Open http://localhost:5173. The start screen asks what you're making. Pick **Notes** to start from a welcome note, or a site kit (blog, docs, portfolio) to start with a site already set up.

For the desktop app, run `pnpm dev:desktop` instead. It opens the folder `~/Documents/Hatch`.

step: Open your own folder
The web app keeps its first vault in the browser, so it works offline and opens with no loading screen. To use a folder on your computer instead, click the vault's name at the top of the sidebar and pick a folder. This needs Chrome, Edge or another browser that can open folders. An Obsidian vault opens as it is.

step: Write a note
Press Ctrl+N (Cmd+N on a Mac) for a new note. Type a title, then:

- Type `[[` and start a note's name to link to it.
- Type `/` for the slash menu: headings, tables, pictures, callouts and components.
- Pick **Chart** from the slash menu to add a chart, written as a fenced block you can edit as text.

Everything saves as you type, as plain Markdown in the vault.

![The slash menu open in a note](https://hatch-docs.pages.dev/assets/slash-menu-light.d61be9d76f.webp)
![The slash menu open in a note](https://hatch-docs.pages.dev/assets/slash-menu-dark.f3d2dcf6a9.webp)

step: Connect an agent
Point your agent at the vault with Hatch's MCP server. For Claude Code:

```sh
claude mcp add hatch -- npx -y @hatchmd/mcp /path/to/your/vault
```

Then ask it something about your notes, like "what's in my cabin plan?" or "file this as a note in Projects". It searches before it writes, and reads the vault's own filing rules first. [Connect an agent](https://hatch-docs.pages.dev/agents/connect-an-agent/) has the setup for other clients.

step: Publish a page
Open Settings, Publish and pick what you're making: a blog, newsletter, portfolio or docs site. Hatch adds a few example notes in a new folder, ready to publish.

![Settings, Publish, asking what you're making](https://hatch-docs.pages.dev/assets/publish-light.c0fe809067.webp)
![Settings, Publish, asking what you're making](https://hatch-docs.pages.dev/assets/publish-dark.2ace267026.webp)

Then **Download as .zip** for any static host, or build it from the command line:

```sh
npx -y -p @hatchmd/publish hatch-site build /path/to/your/vault --out site
```

The `site` folder holds plain HTML you can put on Cloudflare Pages, Netlify, GitHub Pages or your own server. Only the folders you picked leave the vault.
````

## Next steps

```cards
cols: 2
items:
  - title: Components
    text: Charts, tabs, steps, forms and the rest of the blocks a note can hold.
    link: "https://hatch-docs.pages.dev/writing/components/"
  - title: The chat
    text: Ask about your notes and review the edits it proposes.
    link: "https://hatch-docs.pages.dev/agents/the-chat/"
  - title: Site templates and style
    text: Give a blog or portfolio its own look without writing CSS.
    link: "https://hatch-docs.pages.dev/publishing/site-templates-and-style/"
  - title: Deploying Hatch
    text: Run the server for sync, shared vaults and hosted sites.
    link: "https://hatch-docs.pages.dev/self-hosting/deploying-hatch/"
```
