# Sundial docs

## Get started
- [Quick start](https://www.sundial.md/docs): Install, make your first edit with an agent, open your own folder.
- [Privacy and security](https://www.sundial.md/docs/security): Every connection the app makes, what agents can see and do, and how to undo their work.

## Writing
- [Write and review](https://www.sundial.md/docs/writing): Markdown, LaTeX, code, the three modes, suggestions, authorship, history.
- [Agents](https://www.sundial.md/docs/agents): Claude Code and Codex on your machine, Sundial Agent in the cloud, and agents that join from anywhere.
- [Modules](https://www.sundial.md/docs/modules): Templates, checks and skills you add to a workspace, and a first walkthrough.
- [Sharing](https://www.sundial.md/docs/sharing): Share a file, a folder, or the project. Roles, links, the browser, and turning it off.

## Reference
- [Settings and shortcuts](https://www.sundial.md/docs/shortcuts): Every shortcut, the typing rules, tabs and splits, and where each setting lives.
- [FAQ and limits](https://www.sundial.md/docs/faq): Short answers, privacy questions, and what Sundial cannot do yet.

## Agents
- [Start here](https://www.sundial.md/docs/for-agents): What a workspace is to you, the ways in, the facts that unblock the first call, the rules.
- [The skill (/start)](https://www.sundial.md/start): Join, create, live-sync a folder, the template catalog.
- [HTTP contract](https://www.sundial.md/agent-docs): Every endpoint, in full.
- [These docs as markdown](https://www.sundial.md/docs.md): Every page in one file.

## Developers
- [Workspace SDK](https://www.sundial.md/docs/workspace-sdk): How the editor shell is built.
- [Verification](https://www.sundial.md/docs/verification): One contract for every verifier.

---

# Quick start

Install Sundial on your Mac, make your first edit with an agent, and open the folder you already have.

## What Sundial is

Sundial is an editor where you and your agents write in the same document. Markdown, LaTeX with a live PDF, code.

- ![](https://www.sundial.md/docs-icons/folder-simple.svg) Your files are plain files on your disk. Any other tool keeps working on them.
- ![](https://www.sundial.md/docs-icons/terminal.svg) Your agent can be the ![](https://www.sundial.md/agent-logos/claude.svg)Claude Code or ![](https://www.sundial.md/agent-logos/openai.svg)Codex you already pay for, running on your Mac and talking to Anthropic or OpenAI directly, so Sundial never sees those chats. Or an Ollama model that never leaves your computer, or ![](https://www.sundial.md/agent-logos/sundial.svg)Sundial Agent in the cloud.
- ![](https://www.sundial.md/docs-icons/check-circle.svg) Every edit an agent makes is attributed to it and arrives as a suggestion you accept or reject.
- ![](https://www.sundial.md/docs-icons/lock-simple.svg) Your text leaves your machine in [three cases](https://www.sundial.md/docs/security): you share it, you use Sundial Agent, or you use inline AI.

A terminal agent edits files in place. In Sundial the same agent's edits arrive as suggestions, attributed, with history per edit.

## Install in a minute, no account

[Download Sundial for macOS](https://www.sundial.md/download), 13.5 or later, and open it. The web app works in any browser.

If Claude Code or Codex is installed, Sundial finds it and uses it as the default agent. Nothing to configure and no API key. If neither is installed, the chat answers Sign in to chat with Sunny: sign in and chats run on Sundial Agent, [which the app also calls Sunny](https://www.sundial.md/docs/agents).

The desktop app needs no account and no plan. Claude Code and Codex run on your own plan; Sundial never bills for them. Sundial Agent, inline AI and autocomplete spend Sundial credits; a new account starts with free credits and is topped up every month.

## Make your first edit with an agent

Press New project, then Blank project. It opens welcome.md, which contains this sentence:

> the quick brwn fox jumps over lazy dog

1. Highlight the sentence above and press `Cmd+Alt+M` to comment on it.
2. Write "@Agent fix the grammar" and post the comment.
3. The Agent answers on your thread, and its fix lands as a suggestion you accept or reject.

![The comment, the reply, and the suggestion with accept and reject](https://www.sundial.md/docs-images/first-edit.png)

For bigger asks, `Cmd+Shift+J` opens a chat beside the document and `Cmd+J` adds a selection to it; its edits arrive the same way. Suggest is the default for every chat, so nothing becomes final text without you.

## Open the folder you already have

Press New project and pick Open folder, Clone from GitHub, Blank project, or a template.

- Markdown. Wikilinks like `[[note]]`, footnotes, tags, and frontmatter, so an Obsidian vault opens as-is.
- LaTeX. The source beside a live PDF, compiled on your machine.

Edits are written back to the same plain files.

## Share when you are ready

Sign in and [share](https://www.sundial.md/docs/sharing) a file, a folder, or the whole project. What you share syncs live through Sundial's cloud; everything else stays on your machine. Stop sharing and you are fully local again. Sign in also to use Sundial Agent, or to open a workspace at sundial.md in a browser with no install.

That is the whole loop: write, ask, review.

---

# Privacy and security

Every connection the desktop app makes, what each agent can do on your machine, what sharing sends, and what Sundial holds in the cloud.

## Your text leaves your machine in three cases

You share it, you use Sundial Agent, or you use inline AI. Everything else, including every Claude Code and Codex chat in a local project, runs without Sundial in the loop.

Claude Code and Codex run on your machine under your own login, and their requests go to Anthropic or OpenAI directly. Sundial never sees those prompts or your files. Their chats are stored on your Mac under `~/.sundial/desktop`.

## What the desktop app connects to

Sundial Desktop is a native shell around the web app. It loads its interface from sundial.md the way a browser loads a site, and that is the one connection it needs to open. Your files never travel with it: a helper on your Mac reads and writes them, and only the three cases above ever send your text anywhere.

The interface also talks to Sundial for the ordinary reasons an app does:

- ![](https://www.sundial.md/docs-icons/arrows-clockwise.svg) **Updates.** A version check at launch and about once an hour, sending the app's version and platform. A new version installs only when you choose Relaunch.
- ![](https://www.sundial.md/docs-icons/chart-bar.svg) **Usage analytics.** Which screens are used and which errors the interface hits, with sign-in tokens and share links stripped. Off with the same switch as error reports.
- ![](https://www.sundial.md/docs-icons/globe.svg) **Your browser, once.** On first launch the app opens sundial.md/continue, so an invite link you were sent can open in the app.
- ![](https://www.sundial.md/docs-icons/bug.svg) **Error reports.** Only when you are signed in, never file contents; see the last section.

## What each agent can do on your machine

![](https://www.sundial.md/docs-icons/terminal.svg) **Claude Code and Codex.** They can run shell commands in the project folder without asking each time, the way they do in your terminal. Their shell runs as you, so like a terminal it can read what you can read. Their file tools stay inside the folder you opened. File edits still arrive as suggestions. View mode removes their write and shell tools entirely. In a cloud workspace a chat on the Claude Code or Codex tab runs on Sundial's servers, never on your Mac.

![](https://www.sundial.md/docs-icons/cloud.svg) **Sundial Agent.** The model runs on Sundial's servers. In a cloud workspace its commands run in a sandbox, one per agent, never on your machine; the sandbox stops after 15 minutes idle and never lives past 24 hours. In a local project its tools run on your machine, so every message, and every file it reads for that turn, is sent to Sundial. The chat itself stays on your disk.

![](https://www.sundial.md/docs-icons/cpu.svg) **Ollama.** A chat on an Ollama model runs on this computer. Nothing leaves it.

Inline AI (`/ai`, `Cmd+G`, Tune, Resize, autocomplete) runs on Sundial's servers, also in a local project; how it works is on [Write and review](https://www.sundial.md/docs/writing#inline-ai-runs-on-sundials-servers), and what it keeps is under Your data in the cloud below.

## What sharing sends

| You share | What uploads |
| --- | --- |
| A file | The file and its comments |
| A folder | The files inside it |
| The project | The files, and each chat's full history the first time you use it after sharing |
| A chat | That one chat |

Only what you picked syncs. The rest of the project stays on your machine.

From the desktop app, `.env` and `.env.*` files never sync, except templates such as `.env.example`. No other filename is treated as secret: check the share's file list before you turn it on. In a cloud workspace a `.env` you upload is an ordinary document; keep credentials in Workspace secrets instead.

Text files (Markdown, LaTeX, code, CSV) sync as live documents with edit history; images, PDFs and other binaries sync as files without it; `node_modules/`, `.git/`, `dist/`, `build/`, `.venv/`, `.claude/`, lockfiles, `*.min.js`, `*.map` and `*.aux` never sync.

Who can read, comment or edit is set per person or per link; the roles are on [Sharing](https://www.sundial.md/docs/sharing#three-roles).

## Review is the boundary

Every edit is attributed to the human or agent that made it. Chats write suggestions by default, and View mode removes the agent's write tools.

An agent connected from outside suggests when it joins with `editMode` `suggest`, and you can switch any connected agent to Suggest only from its chip: every write then lands as a suggestion and delete, rename, commands and uploads are blocked, whatever token it holds. Its token lasts 7 days.

In a cloud workspace a deleted text file comes back from History with Restore. Undoing a suggestion, and going back to an earlier version, are on [Write and review](https://www.sundial.md/docs/writing#go-back-to-any-point).

## Your data in the cloud

- ![](https://www.sundial.md/docs-icons/hard-drives.svg) **Where.** Files, chats and history in Sundial's database and file store (Supabase); the agent on Fly and its sandbox on Modal.
- ![](https://www.sundial.md/docs-icons/cloud.svg) **Who.** A cloud chat's model call goes through the Vercel AI Gateway to the provider of the model you picked (Anthropic, OpenAI, Google, xAI or an open model). Sign-in is Clerk; analytics is PostHog.
- ![](https://www.sundial.md/docs-icons/lock-simple.svg) **Secrets.** Workspace secrets are encrypted at rest (AES-256-GCM), and when an agent needs a credential from you it sends a link that expires in 15 minutes, so secrets never sit in chat history. Your own provider keys are stored encrypted and used only for runs billed to you.
- ![](https://www.sundial.md/docs-icons/sparkle.svg) **Inline AI.** Sundial keeps the passage you selected, the paragraphs around it, the variants it produced, and which one you chose.
- ![](https://www.sundial.md/docs-icons/folder-simple.svg) **Storage.** 5 GB per free workspace, 50 GB on Pro.
- ![](https://www.sundial.md/docs-icons/check-circle.svg) **Deleting.** Delete a workspace from its row menu on the dashboard (owner only); it disappears from every listing for everyone with access. Delete your account from the profile page in a browser; that removes your account, tokens and workspaces.

Retention, subprocessors and anything this page does not state are in [/privacy](https://www.sundial.md/privacy) and [/terms](https://www.sundial.md/terms).

## Error reports, and the switch that turns reporting off

When you are signed in, the desktop app sends error reports: log lines that mention a failure, never file contents, with every path removed. They travel under your account and are stored against a random install id. Not signed in, nothing is sent. Send anonymous usage and error reports, in the account menu, turns error reports and usage analytics off together; `SUNDIAL_NO_DIAGNOSTICS=1` in the environment turns error reports off as well.

---

# Write and review

Your files open as they are, and every change, yours or an agent's, can be reviewed, attributed, and undone.

## Markdown, and an Obsidian vault as-is

Markdown is the main surface: a rich editor with a raw-source toggle and a slash menu for headings, tables, callouts, images, and code. Type `/` to open the menu.

- Wikilinks like `[[note]]`, footnotes, tags, and frontmatter, so an Obsidian vault opens as-is.
- Math with `$x$` inline and `$$x$$` as a block.
- Mermaid diagrams and highlighted code blocks.
- Highlights with `==text==`, task lists with `- [ ]`, and tables.

Headings and lists fold: `Cmd+Alt+[` collapses everything and `Cmd+Alt+]` expands it. In cloud workspaces, rename a file and every link to it is updated.

## Every other file opens in place

| File | How it opens |
| --- | --- |
| ![](https://www.sundial.md/docs-icons/terminal.svg) Code | A code editor with syntax highlighting. |
| ![](https://www.sundial.md/docs-icons/file-text.svg) CSV | An editable table. |
| ![](https://www.sundial.md/docs-icons/file-text.svg) Images and PDFs | Inline. |
| ![](https://www.sundial.md/docs-icons/file-text.svg) Word, PowerPoint and Excel | A PDF preview. |
| ![](https://www.sundial.md/docs-icons/file-tex.svg) LaTeX (`.tex`) | The source beside a live PDF, compiled on your machine. Cloud workspaces compile with full TeX Live. |
| ![](https://www.sundial.md/docs-icons/file-tex.svg) Notebooks (`.ipynb`) | Opened as text. Sundial Agent can run them in its sandbox. |

## Edit, Suggest, View

Markdown documents have three modes in the control at the top: Edit (the default), Suggest, and View. Code and LaTeX files offer Edit and Suggest. Chats have the same control next to the composer, and they mean the same thing for the agent:

- **Suggest** (the default for agents): every write is a tracked change you accept or reject.
- **Edit**: changes are applied directly. Use it when you trust the task and want speed.
- **View**: the agent's write tools are removed, not just discouraged. It can only read and answer.

![The chat's Suggest control, with Edit, Suggest and View](https://www.sundial.md/docs-images/chat-modes.png)


## Suggestions wait for you

An agent in Suggest mode, or a collaborator with the Commenter role, never changes final text. Their edits appear as tracked insertions and deletions with the author's avatar on each one.

Hover a suggestion to accept or reject it. **Accept all** and **Reject all** are in the bar at the bottom of the document.

![Accept all, Reject all and Preview accepted](https://www.sundial.md/docs-images/review-bar.png)

**Preview accepted**, in that same bar, reads the document as it would stand if every pending suggestion were accepted, without accepting any of them. Toggle it again to bring the markup back.

The Review panel collects pending changes across the whole project so you can work through them in one pass. Filter by file, chat, or author (Sundial Agent, local agents, you and other people), or checkpoints only. The same panel is the History section of the sidebar.

## See who wrote each line

**Show authorship**, in the formatting toolbar, colors each line by who wrote it, human or agent. Hover a colored line for its card and open the chat turn from there.

## Go back to any point

History is kept per edit, not per commit. Scrub through the timeline of a file, or compare any two points. Restore an earlier state. The restore is itself an edit, so nothing is lost.

Name any point in the timeline as a checkpoint, such as "sent to reviewers". Agents can add checkpoints too.

![The History section: pending suggestions with Undo all and Keep all, then every edit and comment](https://www.sundial.md/docs-images/history-panel.png)

Each message from the agent that edited files carries a diff button. It opens exactly what that turn inserted and deleted, across every file it touched, as its own view.

![A chat turn: the comment it answered, its reply, and the change it made to welcome.md](https://www.sundial.md/docs-images/turn-diff.png)

To undo agent work, reject the suggestion, or if the chat was in Edit mode, open the turn's diff from the diff button on its message, or restore from History. Cmd+Z only undoes your own typing, so a collaborator's or agent's change never disappears from under you.

## Inline AI runs on Sundial's servers

Inline AI runs on Sundial's servers, also in a local project. It needs a Sundial account, spends credits, and sends the passage you selected plus the paragraphs around it. Sundial keeps the passage, the paragraphs around it, the variants it produced, and which one you chose. Claude Code and Codex are not used for inline AI; for an edit that never leaves your machine, ask them in a chat or a comment.

- Type `/ai` followed by an instruction to edit in place.
- Select text and press `Cmd+G` for rewrite variants; pick one with a number key.
- **Tune** (tone) and **Resize** (length) live in the same bubble menu that appears over a selection.

## Autocomplete, page setup, Vim

Autocomplete is off by default. Settings → Advanced turns it on as **AI** (a model, spends credits) or **Deterministic** (from the document itself). Tab accepts.

Page setup in the formatting toolbar sets narrow, normal or wide margins and turns the header and footer on or off.

Vim mode, for code and LaTeX files, is under Settings → Shortcuts.

---

# Agents

Which agent runs a chat and who pays, the three ways to ask, what an agent may touch, and how an agent running anywhere else joins.

## Which agent runs a chat, and who pays

A chat runs on Claude Code, Codex, or Sundial Agent. In a local project, Claude Code and Codex run on your Mac on your own plan; Sundial never bills for them, and nothing goes through Sundial: no API key, no credits, no account.

| Agent | Runs where | Who pays | What it sees |
| --- | --- | --- | --- |
| ![Claude Code](https://www.sundial.md/agent-logos/claude.svg) **Claude Code** | In a local project, on your Mac | Your Anthropic plan | The project folder |
| ![Codex](https://www.sundial.md/agent-logos/openai.svg) **Codex** | In a local project, on your Mac | Your OpenAI plan | The project folder |
| ![Sundial Agent](https://www.sundial.md/agent-logos/sundial.svg) **Sundial Agent** | On Sundial's servers, with a sandbox of its own | Sundial credits, or your own provider key under Settings → API keys | The files it works on |
| ![](https://www.sundial.md/docs-icons/cpu.svg) **Ollama Agent** (desktop) | On this computer, on a model Ollama serves. Nothing leaves it. | Nothing | The project folder |
| ![](https://www.sundial.md/docs-icons/sparkle.svg) **Tinker Agent** (desktop) | On this computer, calling your fine-tuned checkpoints on Thinking Machines' endpoint | Your Tinker key | The project folder |

In a cloud workspace the same Claude Code and Codex tabs run on Sundial's servers, on the Claude or ChatGPT subscription you connect under Settings → API keys, or on Sundial credits.

If Claude Code or Codex is installed, it is the default. The composer shows which one a chat runs on; pick one in the model menu. In a local project a chat keeps its agent once it has messages; to switch, start a new chat. A new chat starts on the last model you picked. Sundial Agent can switch models mid-chat from the catalog; Claude Code and Codex run only their own provider's models.

Claude Code and Codex sessions already on your Mac can be imported as chats and resumed in the editor.

![The model menu in the chat composer](https://www.sundial.md/docs-images/model-menu.png)

## One agent, three names

The hosted agent is Sundial Agent. The app also calls it Sunny, and in a comment it answers to @Agent (also @Sunny, @Claude, @Codex). Ask Sunny for help, in the sidebar, is a separate support chat with the Sundial team.

## Ask from a chat, a comment, or the page

![](https://www.sundial.md/docs-icons/chat-circle.svg) **A chat.** `Cmd+Shift+J` opens one. To point the agent at a passage, select it and press `Cmd+J`. The selection is added to the chat as context, so you can say "make this shorter" without pasting anything. Attach a whole file with the paperclip, or drag it in.

![](https://www.sundial.md/docs-icons/chat-text.svg) **A comment.** Select text and press `Cmd+Alt+M`, or use the comment button in the bubble menu. The thread is anchored to that selection and stays attached as the text moves. Start a comment with `@Agent` and the agent replies in the thread. Its fix arrives as a suggestion on exactly that selection, so a review pass can be a set of margin notes:

```prompt
@Agent this paragraph repeats the intro. Cut it to one sentence.
```

The **Delegate** button on any thread does the same for a comment that was written without the mention. A chat can watch a document (chat menu → Watch comments); from then on every new thread on it goes to that chat, no mention needed.

![](https://www.sundial.md/docs-icons/text-aa.svg) **The page.** Type `/ai`, or select text and press `Cmd+G`. Inline AI runs on Sundial's servers; [Write and review](https://www.sundial.md/docs/writing#inline-ai-runs-on-sundials-servers) says what it keeps.

## What an agent may touch

Agents read, write, and search the project's files, reply to comments, add checkpoints, and look through history. Suggest makes every write a tracked change, Edit applies it directly, View removes the write tools; the modes are on [Write and review](https://www.sundial.md/docs/writing). On your Mac, Claude Code and Codex can also run commands in the project folder without asking each time; View mode removes that ([Privacy and security](https://www.sundial.md/docs/security#what-each-agent-can-do-on-your-machine)). Sundial Agent also has a shell in its sandbox, so it can install packages, run scripts, and compile LaTeX without touching your machine.

Instructions to the agent live in the root `AGENTS.md`; Settings → Workspace edits that file. Skills live under `skills/<id>/SKILL.md`.

## Templates, skills and assistants

A module is a folder of files plus a short manifest: a venue template, a check that runs on every edit, or a skill the agent follows. Add one from the gallery at [/modules](https://www.sundial.md/modules) or the Modules section of the sidebar; every file it adds is yours. What adding one does, and a first walkthrough, are on [Modules](https://www.sundial.md/docs/modules).

## An agent running anywhere else can join

A Claude Code in a terminal or ChatGPT in a browser tab can join a shared workspace through Open with. That is the last icon in the sidebar strip, also in the `Cmd+T` launcher in cloud workspaces. It hands the agent a one-line prompt: fetch sundial.md/start, then join this workspace. The agent shows up as a collaborator with its own cursor and its edits are tracked under its name; switch it to Suggest only from its chip to keep every write a suggestion. The workspace has to be [shared](https://www.sundial.md/docs/sharing) first, so it has an address to reach.

In a cloud workspace, Settings → Advanced → MCP connections (beta) prints the exact command:

```bash
claude mcp add --transport http sundial "https://www.sundial.md/mcp?workspace=<id>" && claude mcp login sundial
```

```bash
codex mcp add sundial --url "https://www.sundial.md/mcp?workspace=<id>" && codex mcp login sundial
```

The login step authenticates through the browser once. The rules an outside agent follows are on [Start here](https://www.sundial.md/docs/for-agents).

---

# Modules

Templates, checks and skills you add to a workspace. What a module is, what adding one does, and a first walkthrough.

## What a module is

A module is a folder of files plus a short manifest: a name, a description, the file to open first, a message for the first chat, and, for some, a setup command, a button for selected text, or a check that runs on every edit. Everything a module adds to a workspace is a file you can open, edit or delete.

The gallery at [/modules](https://www.sundial.md/modules) shows them in three groups:

| Group | What it is | Examples |
| --- | --- | --- |
| ![](https://www.sundial.md/docs-icons/check-circle.svg) **Checks your work** | A verifier: a proof, a claim, a compile. It says only what it checked. | Claim Verifier, Lean Blueprint, the LaTeX compiler |
| ![](https://www.sundial.md/docs-icons/file-tex.svg) **Paper templates** | Files to start from, in the venue's official style, compiled on open. | ICLR 2026, NeurIPS, a thesis, a talk |
| ![](https://www.sundial.md/docs-icons/sparkle.svg) **Skills and assistants** | Something Sunny knows how to do when you ask, or does on its own when you select text. | Literature search, Formalize |

## Why they are useful

A template saves the afternoon of finding the right class files and getting them to compile: the paper opens with its PDF beside it. A verifier turns "is this right?" into a button, and it reports only what it actually checked. A skill gives the agent a written method to follow, so you do not have to explain it in every chat.

## What adding one does

Add a module from the gallery, or from the **Modules** section at the top of the sidebar, where Recommended rows are picked from the files you already have.

![The Modules section of the sidebar, with the built-in LaTeX compiler and recommended checks](https://www.sundial.md/docs-images/modules-section.png)

- Its files land at the root of the workspace. A name that already exists gets a `-<module>` suffix; nothing of yours is overwritten.
- Its instructions join the agent's context, and its opening message appears in a new chat with suggested first asks.
- A setup command, when the module has one, runs in the agent's cloud sandbox, never on your Mac.
- A selected-text action, such as Verify or Formalize, appears in the toolbar over any selection. Its verdict lands as a comment thread on that selection.
- A verifier's checks run on every edit from then on.

Remove a module from the same section. Its instructions, buttons and checks go; the files it added stay, because they are yours now.

## Try it in five minutes

1. Open [sundial.md/new](https://www.sundial.md/new). A fresh workspace asks what it is for and shows the gallery.

   ![A new workspace opens on the gallery: what is this workspace for?](https://www.sundial.md/docs-images/modules-gallery.png)

2. Add **ICLR 2026**. The paper opens as `main.tex` with the compiled PDF beside it, in the official style.
3. Add **Claim Verifier**. Select a sentence in the paper, click **Verify** in the toolbar, and read the verdict in the thread that appears on it.
4. In the chat, try one of the suggested asks the module posted, then write your own.
5. Done with a check? Remove it from the Modules section. Your paper stays.

Templates work the same way on the desktop: New project, then a template.

---

# Sharing

Share a file, a folder, or the project, give each person a role, work together in the browser, and turn the share off when you are done.

## Share a file, a folder, or the project

Sharing needs a Sundial account. Choose Share from a file's or folder's row in the sidebar, or from the Share button in the top bar, which can also share the whole project:

- **A file**: that document, and the comments made on it while it is shared.
- **A folder**: the files inside it.
- **The project**: everything, plus the chats you use after sharing.

Only what you picked syncs. The rest of the project stays on your machine. What each scope uploads and the `.env` rule: [Privacy and security](https://www.sundial.md/docs/security#what-sharing-sends).

## Three roles

Invite people by email, or turn on "Anyone with the link", at one of three levels. Someone invited by email joins on sign-in.

| Role | Can |
| --- | --- |
| ![](https://www.sundial.md/docs-icons/eye.svg) **Viewer** | Read. |
| ![](https://www.sundial.md/docs-icons/chat-text.svg) **Commenter** | Read and comment. Signed in, their edits arrive as suggestions, the same way agent edits do. |
| ![](https://www.sundial.md/docs-icons/pencil-simple.svg) **Editor** | Edit directly. |

Set the link back to Restricted in the Share menu to revoke it.

![The Share dialog: invite by email with a role, the people with access, and general access](https://www.sundial.md/docs-images/share-modal.png)

## Working together in the browser

Collaborators show up as live cursors, and comments and suggestions flow both ways. Someone without the desktop app opens the same document at sundial.md in a browser: the same editor, suggestions, review, comments and history. Their edits are attributed to them like everyone else's.

A cloud workspace, made at [sundial.md/new](https://www.sundial.md/new), lives on Sundial's servers and is live multiplayer by default; what that means for your data, and how to delete it, is on [Privacy and security](https://www.sundial.md/docs/security#your-data-in-the-cloud).

Sign in to see workspaces shared with you on the home screen.

On a phone the layout is a reader and a chat surface, not the full editor; suggestions and comments work ([FAQ and limits](https://www.sundial.md/docs/faq#what-sundial-cannot-do-yet)).

## Stop sharing and you are local again

Open the same Share menu and turn the share off. Your copy stays on disk and you are fully local again.

---

# Settings and shortcuts

Every keyboard shortcut and typing rule, the tab and sidebar keys, and where each setting lives.

## Every shortcut, from the same list Settings uses

In a browser on Windows or Linux, `Cmd` is `Ctrl`, and `Cmd+O` also opens a file or chat. Shortcuts marked desktop only need the desktop app, because browsers reserve the combination. Anything not marked fixed can be rebound under Settings → Shortcuts.

| Shortcut | Action | Notes |
| --- | --- | --- |
| `Cmd+K` | Search files, chats, and actions |  |
| `Cmd+P` | Open a file or chat |  |
| `Cmd+N` | New file | desktop only |
| `Cmd+T` | New tab | desktop only |
| `Cmd+W` | Close tab | desktop only, fixed |
| `Ctrl+Tab` | Next tab | desktop only |
| `Ctrl+Shift+Tab` | Previous tab | desktop only |
| `Cmd+Shift+T` | Reopen closed tab | desktop only |
| `Cmd+O` | Open folder | desktop only, fixed |
| `Cmd+J` | Add selection to chat |  |
| `Cmd+Shift+J` | New chat |  |
| `Cmd+\` | Toggle left panel |  |
| `Cmd+,` | Open settings |  |
| `Cmd+.` | Open the launcher bar |  |
| `Cmd+K` | Insert or edit link (text selected) | fixed |
| `Cmd+F` | Find in document | fixed |
| `Cmd+Shift+H` | Find and replace | fixed |
| `Cmd+Alt+[` | Collapse all headings and lists | fixed |
| `Cmd+Alt+]` | Expand all headings and lists | fixed |
| `Cmd+Alt+M` | New comment | fixed |

## Markdown typing shortcuts

Text typed into the document that turns into formatting.

| Type | Result |
| --- | --- |
| `# … ###### + space` | Heading 1–6 (start of line) |
| `- + space` | Bullet list |
| `1. + space` | Numbered list |
| `- [ ] + space` | Task list |
| `> + space` | Quote |
| ````` | Code block |
| `---` | Divider |
| `**text**` | Bold |
| `*text*` | Italic |
| `~~text~~` | Strikethrough |
| ``text`` | Inline code |
| `==text==` | Highlight |
| `$x$ / $$x$$` | Math (inline / block) |
| `[[name]]` | Link to another file |

## Tabs, splits, and the sidebar

Drag a tab onto the edge of the center to split it. `Cmd+T` (desktop) opens a new tab offering Create new file, Open file, New chat, and, in cloud workspaces, Open with. `Cmd+\` hides the sidebar (Toggle left panel in the table above); the strip at its top turns Modules, Files, Chats, Source control and History on or off.

## Where each setting lives

| Tab | What it holds |
| --- | --- |
| **Appearance** | Light, dark, or system theme. Tabs or no tabs across the top of the center. |
| **Advanced** | Ask Sunny for help, Autocomplete (AI or Deterministic, and which model), PDF comments, Modules-first workspaces. In cloud workspaces, MCP connections (beta) with the command filled in. |
| **Shortcuts** | Click a shortcut and press the new keys. Delete restores one default; Reset all restores every one. Vim mode for code and LaTeX files is on this tab. |
| **Get set up** | The onboarding checklist. |
| **Billing** | Sundial credits and your plan. |
| **API keys** | Your own Anthropic, OpenAI, Google AI Studio or xAI key, and the Claude Code and Codex subscription connections. |
| **Ollama** and **Tinker** (desktop) | Ollama on this computer; Tinker's hosted endpoint. |
| **GitHub** and **Overleaf** (cloud) | Repository and project sync. |
| **Workspace** | Instructions applied to every chat. When the workspace has a root `AGENTS.md`, this tab edits that file; Move to AGENTS.md creates it ([Agents](https://www.sundial.md/docs/agents)). |
| **Secrets** (cloud, owner only) | Credentials for the agent's sandbox; see [Privacy and security](https://www.sundial.md/docs/security). |

There is no default model setting; a new chat starts on the last model you picked. On the document itself, Page setup and Show authorship are in the formatting toolbar; the ⋯ menu switches rendered and raw Markdown, shows the word count and file title, and downloads as PDF or Word in cloud workspaces.

---

# FAQ and limits

Short answers to the questions people ask first, the privacy ones, and the single list of what Sundial cannot do yet.

## Getting started

**Do I need an account?** No. The desktop app edits local folders and runs Claude Code or Codex with no account. You need one to share, to use Sundial Agent, or to use the web app.

**Which agent is it using?** The composer names it. Claude Code or Codex when one is installed, otherwise Sundial Agent once you sign in. In a local project a chat keeps its agent once it has messages; to switch, start a new chat.

**The chat says Sign in to chat with Sunny.** Install Claude Code or Codex and sign in to it in your terminal, then start a new chat, or sign in to Sundial to use Sundial Agent.

**Is Sunny the same as Sundial Agent?** Yes; in a comment it answers to @Agent. Ask Sunny for help is the separate support chat.

**How much does it cost?** The desktop app needs no account and no plan; only Sundial Agent, inline AI and autocomplete spend Sundial credits ([Quick start](https://www.sundial.md/docs)). Storage: 5 GB per free workspace, 50 GB on Pro.

**Where are my files?** In the folder you opened. Sundial writes plain files back to disk; nothing is locked in a database. Sundial's own data for a local project (chats, settings) lives under `~/.sundial/desktop`. Quit or uninstall the app and your folder is untouched.

## Editing

**The agent changed the text directly instead of suggesting.** The chat was in Edit mode. Switch the control next to the composer back to Suggest. To undo, open the turn's diff from the diff button on its message, or restore from History.

**How do I undo an agent's suggestion?** Reject it. Hover the change, or use Reject all at the bottom of the document.

**Can I see everything an agent changed today?** The Review panel lists changes across the project; filter it to today, a chat, or an author. Show authorship colors every line by who wrote it.

**My Obsidian vault has wikilinks and frontmatter.** They render in place. Open the vault folder as a project.

**Does it do LaTeX?** Yes. The source opens beside a live PDF, compiled on your machine.

**I cloned a repository: who commits?** You do, with git as usual, or ask Claude Code or Codex in a chat, which has your shell.

**Which key is it, Cmd+Option+M or Cmd+Alt+M?** `Cmd+Alt+M`; the app and the [Shortcuts](https://www.sundial.md/docs/shortcuts) table use that spelling.

## Privacy and your data

**What leaves my machine?** Your text leaves your machine in three cases: you share it, you use Sundial Agent, or you use inline AI. [Privacy and security](https://www.sundial.md/docs/security) lists every connection the app makes.

**Can Claude Code run commands on my machine from Sundial, and will it ask first?** Claude Code and Codex can run shell commands in the project folder without asking each time, the way they do in your terminal. Their shell runs as you, so like a terminal it can read what you can read. The rest is on [Privacy and security](https://www.sundial.md/docs/security#what-each-agent-can-do-on-your-machine).

**Does Sundial train on my documents?** Inline AI keeps the passage you selected, the paragraphs around it, the variants and your choice. Chats and files that never leave your machine are never seen by Sundial. For everything else, see [/privacy](https://www.sundial.md/privacy) and [/terms](https://www.sundial.md/terms).

**Can I use Sundial for work under an NDA?** With Claude Code or Codex, no sharing and no inline AI, Sundial holds none of your text; the three exceptions are on [Privacy and security](https://www.sundial.md/docs/security).

**Can I turn off what the app reports about itself?** Yes. Send anonymous usage and error reports, in the account menu of the desktop app, turns off both error reports and usage analytics.

**Does the app work offline or behind a firewall?** The interface loads from www.sundial.md on every launch, so the app needs to reach it to open. Claude Code and Codex chats then need Anthropic or OpenAI, nothing else; your files never leave your disk for that.

**How do I delete a workspace or my account?** Delete a workspace from its row menu on the dashboard (owner only). Delete your account from the profile page in a browser; that removes your account, tokens and workspaces. More on [Privacy and security](https://www.sundial.md/docs/security#your-data-in-the-cloud).

## Sharing and sync

**Someone I shared with sees an old version.** Sharing syncs live while the share is on. Check that the file is inside the shared scope, and that neither of you is offline.

**I saved a `.env` in a shared folder and it never synced.** From the desktop app, `.env` and `.env.*` files, and folders like `node_modules/` and `.git/`, never sync.

**How do two people work on a desktop project?** Sharing needs a Sundial account for the person sharing; the other person opens the document at sundial.md in a browser at the role you gave them.

## What Sundial cannot do yet

<!-- mirrors content/support-limits.md; change both -->

**Cloud only.** These work only in cloud workspaces on sundial.md, not in the desktop app: two-way GitHub sync (edits become commits, pushes arrive as edits), scheduled tasks that post a prompt into a chat on a cadence, skills installed from a URL, LaTeX with a full TeX Live compiler, and export to PDF and Word. So do Overleaf sync, workspace secrets and the agent's sandbox shell.

**On a phone.** The phone layout is a reader and a chat surface, not the full editor: no tabs or splits, panels open full screen, settings cannot be opened, Open with is unavailable, and the layout is not remembered between visits.

**Files.** Only the listed text formats are live documents; everything else syncs as a file with no diff and no edit history. A text file over 10 MB is stored as a file. LaTeX compiles only from a `.tex` root. Office files preview as PDF.

## Getting help

Ask Sunny for help, in the sidebar, opens a support chat with the Sundial team. It sends your message, any attachments you add (up to 5 files, 100 MB each and 200 MB total), the workspace id, and your email if you are signed in or one you type, so the reply can reach your inbox. On these docs pages, the Ask a question panel answers from this documentation.

---

# Sundial for agents

What a Sundial workspace is to an agent, the ways in, the six facts that unblock the first call, and the rules.

## What you are looking at

A Sundial workspace is a folder of files that humans and agents edit together. Every file is a live document. Every edit is attributed to whoever made it, human or agent, and an agent's edits arrive as suggestions the human accepts or rejects. You are a visible participant with a presence chip and a cursor, not a background script.

These docs are plain markdown. Fetch [/docs.md](https://www.sundial.md/docs.md) for every page in one file, or `/docs.md?page=for-agents` for one page.

## How you arrived, and what your credential is

| You have | Do this |
| --- | --- |
| Claude Code or Codex launched by the desktop app | Nothing. You are that chat's agent. Write with your normal tools and Sundial tracks the edits. |
| A `/w/<slug>?anon=<key>` link, which is what Open with copies | Fetch [/start](https://www.sundial.md/start). `anon` is your key: `key=` on every `/g/` URL, or `Cookie: sd_anon=<key>` on the join call. |
| A pasted join prompt with the token and workspace id inline | Run its first command. It is the contract. |
| An Open with prompt: "Fetch /start and follow it, then join my workspace at <url>" | If that URL carries `anon=`, that is your key. If it carries nothing, you hold no credential yet. Say so and ask the human for the `anon=` link, a join prompt, or an MCP connection after they sign in. |
| A bare `/w/<slug>` | The same: no credential yet. |
| Nothing yet | [/start](https://www.sundial.md/start) creates a live, writable workspace in two calls, no account needed. |

## Six facts that unblock the first call

1. Call `https://www.sundial.md` exactly. The apex redirects and curl drops your headers on the way, so the wrong host is a 401. A localhost workspace is unreachable from outside.
2. Two headers on every request: `Authorization: Bearer <token>` and `X-Agent-Id: ai:<your-name>`, kept stable. Omit the id and you are `ai:local-agent`, the same name as every other agent that omitted it.
3. `workspaceId` is the UUID; a slug returns 401. `POST /api/workspace/local-agent/join` with `{"projectId":"<slug>"}` and your `sd_anon` cookie returns the UUID as `workspaceId` and a token good for 7 days.
4. Every write is a suggestion unless its body carries `"editMode":"edit"`, and only when the human asked for direct edits. Join with `{"editMode":"suggest"}` unless they did; that locks your token. The human can also switch you to Suggest only from your chip, which blocks delete, rename, exec and uploads.
5. The token is a secret. Never paste it into chat or into a file. The link that carries `anon=` or `token=` is the same: never write it into a file, a commit, or a shared channel.
6. Fetch /start with whatever tool you have. A browsing tool gets the GET-only edition, where every operation is a URL under `/g/` and your key rides in the query. A shell gets the full API. [/start.md](https://www.sundial.md/start.md) is always the markdown.

Connecting is one call, `GET /api/workspace/local-agent/files?workspaceId=<uuid>`: it registers your presence and returns the tree. Every endpoint is in [/agent-docs](https://www.sundial.md/agent-docs); the workflow is in [/start](https://www.sundial.md/start).

## Feedback arrives on GET /events

Feedback arrives on `GET /events`: the human's comments on your work and their accept or reject on each suggestion, keyed by the `suggestionId` your write returned. Reply in the thread, revise, watch again. Never re-apply a rejected suggestion.

`GET /file` and `GET /grep` return the document as if every pending suggestion were accepted, yours and others'; a rejected suggestion's text disappears from later reads. Check `GET /suggestions` before anchoring an edit on text that might be someone's unreviewed proposal.

## The rules

- **Suggest by default.** Every write is a suggestion unless its body carries `"editMode":"edit"` and the human asked for direct edits.
- **Edit, do not overwrite.** Anchor edits on exact existing text. A whole-file write on a document someone else is typing in loses their work.
- **Say what you did.** Report back in the chat or the thread you were asked in, briefly, and end with the question that moves the work forward.
- **The token is a secret.** Never paste it into chat or into a file.

## MCP, once the human is signed in

MCP is for a signed-in human who wants a permanent connection to every workspace on their account; in a cloud workspace, Settings → Advanced → MCP connections prints the command. Start over HTTP.

## Install the pointer

Install a pointer, never a snapshot. A downloaded copy of `/start` goes stale. The install stub in [/start](https://www.sundial.md/start) triggers on Sundial links and always follows the live version. It works for Claude Code at `~/.claude/skills/sundial/SKILL.md` and for Codex at `~/.codex/skills/sundial/SKILL.md`.

## Where everything else is

- [/start](https://www.sundial.md/start): the skill. Joining, creating, the local-folder live sync, and the template catalog.
- [/agent-docs](https://www.sundial.md/agent-docs): the HTTP contract, every endpoint in full.
- [/llms.txt](https://www.sundial.md/llms.txt): the signpost crawlers probe first.
- [/templates.md](https://www.sundial.md/templates.md): every template slug you can create a workspace from.
- [/.well-known/agent.json](https://www.sundial.md/.well-known/agent.json): the discovery manifest.
