Playbook
One Brain, Two Workbenches: Using Claude Desktop and Claude Code Together
How I build Y-Verge Lab by switching between the Claude desktop app and Claude Code in the terminal without losing context: what each one is for, the four rules for running both, and the two small files that carry the work across.
I build Y-Verge Lab in public. What I publish here is something I learned by doing, written down so others can run it too. This playbook is one of those: the workflow I ended up with while building the site itself.
Building Y-Verge Lab in two directions at once
The build never went in a straight line. First I worked on the structure: which pages exist, how they connect, where the Lab lives, what each page needs to show. That is technical work, and it belongs in code, with Claude Code in the folder where the SvelteKit project lives.
Then I'd step back, look at what I'd built, and see that the structure worked but the experience didn't yet. A page needed a clearer path to the next step. A section needed to feel less like a template and more like Y-Verge. Firming up the UX and the look is creative work, and for that I want room to sketch, compare options and think out loud in the Claude desktop app.
Then back to the code again. Structure, then look, then structure. Every switch risked leaving something behind: the reasoning for a design choice stayed in one conversation, while the code only knew what had been decided, not why.
There was a second problem hiding under the first: my documents were scattered across too many places. Notes sat in desktop chats, drafts in Claude artifacts, plans in files next to the code. I prefer to work in Notion, where I can organise everything around my own workflow, search it and come back to it months later. But most documents are born as Claude artifacts first, and I like it that way for the first round, when ideas move fast and sketches change by the minute. As a piece gets close to done, I want it in Notion, where I can review it properly and find it again later.
What made it work was the same pipeline I use for my study guides: research and sketches in a Claude doc, review in Notion, then sync back so the code is built from what was agreed. At first the sync ran one way: the Claude doc was pushed to Notion for review, and that was it. Once I was reviewing and editing in Notion every week, that wasn't enough, so we upgraded the pipeline skill to a two-way sync. Now edits and comments on the Notion page flow back into the Claude doc, and changes to the doc update the Notion page. The two never drift apart, and the code always has one clear source to build from.
Learning in public means showing the messy middle, not only the finished site. So this is the workflow as it actually runs: what each tool is good at, how work crosses from one to the other, and the small files that carry the context in between. Use it as it is, or as a starting point for your own.
Why this matters
Yes, you can work in the Claude desktop app and in Claude Code in your terminal at the same time, and you can hand work from one to the other. The catch is that a desktop chat and a terminal session don't share a conversation, so the handoff has to travel through something both can read: files in a shared project folder.
Most real projects need two kinds of thinking. One is open and exploratory: researching a topic, sketching ideas, drafting, reviewing in Notion. The other is precise and hands-on: writing code, running a dev server, fixing a failing build. The desktop app is built for the first; the terminal for the second. Moving between them without losing context is what turns two tools into one workflow.
Conversations don't travel between Chat and the terminal. Files do.
Everything here was checked against Anthropic's documentation in November 2026. Features change quickly, so the Sources section at the end links to the pages to re-check.
The two workbenches (and the third one hiding inside)
There are really three places Claude works on your computer: the desktop app's Chat, the desktop app's Code tab, and the claude command in your terminal. The last two run the same Claude Code engine; Chat is a different surface with its own conversations.
The desktop app puts Claude Code in the Code tab at the top of the sidebar, and ships with it built in, so the Code tab works without installing Node.js or the CLI. The terminal CLI is installed separately. According to the docs, Desktop runs the same underlying engine as the CLI with a graphical interface, and the two read the same CLAUDE.md files.
| Workbench | Best for | Remembers between sessions through | Can move a session to |
|---|---|---|---|
| Desktop app, Chat | Research, explaining, drafting docs and artifacts, Notion review, visual sketches | Its own chat history and memory; files you ask it to save | Nowhere directly; hand off through files |
| Desktop app, Code tab | Coding with a visual diff view, parallel sessions in a sidebar, app preview pane | Session list in the app; CLAUDE.md in the project | Cloud, or an editor or file manager on its folder |
Terminal CLI (claude) | Scripting, automation, dev servers, fast keyboard-driven coding | Session transcripts per project folder; CLAUDE.md | The desktop Code tab, with /desktop or claude --desktop |
The docs sum up the split well: use Desktop to manage parallel sessions, arrange panes side by side or review changes visually; use the CLI for scripting, automation, or if you simply prefer a terminal (Coming from the CLI).
My rule for Y-Verge Lab work: thinking happens in Chat, building happens in the Code tab or the terminal.
Can you run both at once? Yes, with four rules
Running both at once is officially supported: the docs say you can run Desktop and the CLI simultaneously on the same machine, even on the same project. Four rules keep it smooth.
- One usage budget feeds both. On Pro and Max plans, limits are shared across Claude and Claude Code, so all activity in both counts against the same limits. Two busy sessions in parallel drain your 5-hour and weekly allowance about twice as fast. Check where you stand with
/usagein Claude Code. - Sign in with your plan, not an API key. If an
ANTHROPIC_API_KEYenvironment variable is set, Claude Code uses that key instead of your subscription and bills at API rates. Run/logininside Claude Code to switch back to your plan. - Conversations don't cross over by themselves. Each surface keeps its own session list (Manage sessions). A desktop chat can't see what you told the terminal, and the reverse. Shared context has to live in files, which the rest of this playbook is about.
- Don't let two Claudes edit the same files at once. Both can write to the same folder, and the second writer wins. Split the work by folder, commit to git before switching, or give a parallel coding session its own git worktree:
claude --worktreein the CLI, or the Worktree toggle in the desktop Code tab, which keeps worktrees in<project-root>/.claude/worktrees/(desktop docs). One more trap: if you resume the same session in two terminals without forking, messages from both interleave into one transcript.
The core idea: hand off through files, not chat
The project folder is the only thing all three workbenches can read, so it carries the context from one to the next.
The one direct link is between the terminal and the desktop Code tab, which can pass a whole session back and forth. Everything else crosses through the folder: handoff.md for what's changing, CLAUDE.md for the rules that don't.
Step by step: desktop to terminal
The handoff takes about five minutes the first time and under a minute after that. The route depends on where in the desktop app you were working.
The note in step 2 is the only thing that crosses from chat to terminal; everything after it runs in the terminal.
Route A: from a desktop chat (research, planning, drafting)
- Pick one project folder as the meeting point, for example
~/Projects/yverge-lab. Everything both sides need will live here. - Connect that folder to the desktop chat. In the Claude desktop app, open the + menu in the chat, choose Add folder and select the project folder. Claude in that chat can now read and write files there.
- Do the thinking work in the chat. Research, outline, sketch diagrams, draft, review in Notion. Nothing about this step changes.
- Ask for a handoff note before you switch. Say: "Write a handoff.md in the project folder with the goal, what we decided, the files that matter, and the next steps." The template below shows what a good one contains.
- Make sure the project has a CLAUDE.md. It holds the rules that are true every session: the stack, the commands, the conventions. Claude Code loads CLAUDE.md at the start of every session, so you never re-explain the project. If you don't have one yet, run
/initin Claude Code and it generates a starting CLAUDE.md by analysing your codebase. - Commit (optional, recommended).
git add -A && git commit -m "handoff: ready for build"gives you a clean point to return to if the build goes sideways. - Start Claude Code in the same folder and give it the note (commands below). Then type: "Read handoff.md and continue from Next steps." The
-nflag names the session so you can come back to it withclaude --resume study-guide-build. - Check that the context loaded. Run
/memory; it lists every CLAUDE.md and rules file loaded in the session. If CLAUDE.md is missing from that list, you started in the wrong folder.
cd ~/Projects/yverge-lab
claude -n study-guide-build
Route B: from the desktop Code tab (a coding session)
The Code tab and the CLI share configuration, so CLAUDE.md, CLAUDE.local.md, MCP servers in ~/.claude.json or .mcp.json, hooks, skills and settings apply to both. What doesn't carry over is the conversation itself: the docs note that a desktop-app session resumes in the desktop app. So use the same file handoff as Route A, steps 4 to 8.
If you know you'll bounce a coding session back and forth, start it in the terminal. A CLI-born session can move into Desktop and back again with its full history.
Step by step: terminal back to desktop
Going from the terminal to the desktop app is easier, because Claude Code can move a terminal session into the desktop Code tab with its full conversation. Going back into a desktop chat still runs through files.
Only the terminal-to-Code-tab step carries a whole conversation; every other step carries a note.
Into the desktop Code tab (keeps the whole conversation)
| Where you are | Command | What happens |
|---|---|---|
| Inside a running terminal session | /desktop | Claude saves the session, opens it in the desktop app, then exits the CLI |
| In your shell, no session open | claude --desktop --continue | Opens the most recent session from this folder in Desktop |
| In your shell, a specific session | claude --desktop --resume <session-id> | Opens that session in Desktop; get the ID from /status. A session name doesn't work here |
| Inside the desktop Code tab | /resume | Lists sessions you started from the CLI on this computer; search by title, folder or branch, then press Enter |
For the last route:
- Close the session in the terminal. Claude Code won't move a session that is open in another terminal or still running in the background.
- In the desktop Code tab prompt box, type
/resume. - Pick the session. It continues with its full conversation and context.
The round trip is real: Desktop continues the same session rather than a copy, so claude --resume in the terminal still finds it afterwards.
Limits worth knowing: /desktop and claude --desktop work on macOS and x64 Windows when you're signed in with a Claude subscription, not with an API key or a third-party cloud provider. claude --desktop needs Claude Code v2.1.285 or later. Desktop's /resume works in local sessions, not SSH, WSL or cloud sessions (desktop docs).
Into a desktop chat (research and review)
- Before you leave the terminal, tell Claude Code: "Update handoff.md: what you built, what's tested, what's still open, and questions for the next research pass."
- Commit.
- In the desktop chat that has the folder connected, say: "Read handoff.md and the changed files, then help me review."
That's the loop: each side leaves a note before it hands over, and the other side starts by reading it.
Templates you can copy
Two files do all the work: handoff.md changes every time you switch, and CLAUDE.md changes rarely.
| File | Changes | Who writes it | Loaded automatically? |
|---|---|---|---|
handoff.md | Every switch | Whichever side is handing over | No: tell Claude to read it |
CLAUDE.md | When the project's rules change | You, or /init to start | Yes, at the start of every Claude Code session, in both the CLI and the desktop Code tab |
handoff.md
# Handoff: <short title>
Updated: <date> · From: <desktop chat | Code tab | terminal> · To: <...>
## Goal
One or two sentences: what this piece of work is for.
## Decided
- Decision, and the reason in a few words
- ...
## Files that matter
- `notes/study-guide.md`: the reviewed content
- `src/routes/guide/+page.svelte`: where it renders
## Next steps
1. First concrete action
2. Second
3. Third
## Open questions
- Anything the next side should ask about before guessing
## Done means
- How to check the work is finished (a command, a page that renders, a test that passes)
Keep it under one screen. If it grows, the extra detail belongs in its own file that the handoff links to.
CLAUDE.md
# Project: Y-Verge Lab resources
## Stack
- SvelteKit app; study aids are SVG diagrams in `src/lib/diagrams/`
## Commands
- Dev server: `npm run dev`
- Before committing: `npm run check && npm test`
## Conventions
- One study guide per folder under `content/guides/<slug>/`
- Diagrams: one component per file, named after the concept
## Workflow
- Read `handoff.md` at the start of a session if it exists
- Update `handoff.md` before you stop
- Never push directly to main
@handoff.md
The last line is an import: CLAUDE.md can pull in other files with @path, so every session starts with the latest handoff already loaded. Remove it if you'd rather ask for it explicitly. The stack and commands above are placeholders: replace them with the real ones from your project.
Three rules from the docs for a good CLAUDE.md:
- Keep each file under about 200 lines; longer files use more context and reduce adherence.
- Write instructions you can check, like "Run
npm testbefore committing", not "format code properly". - CLAUDE.md is guidance, not enforcement. For something that must happen every time, such as a check before every commit, use a hook.
Personal settings that shouldn't go into git (your sandbox URLs, local paths) go in CLAUDE.local.md, which loads alongside CLAUDE.md; add it to .gitignore.
Worked example: a study guide becomes a Svelte page
In my study-guide pipeline, the handoff happens at stage 4: that's where the reviewed notes stop being a document and become files in a folder Claude Code can build on.
The pipeline has five stages: research, a Claude doc, Notion review, sync back, and code development. Here is where each one runs and what it leaves behind for the next.
| Stage | Workbench | What you say | Leaves behind |
|---|---|---|---|
| 1. Research and verify | Desktop chat | "Make a study guide on <topic> using the study guide pipeline" | Checked sources, runnable code samples |
| 2. Claude doc | Desktop chat | (continues automatically) | The master copy, with a sketch for every concept |
| 3. Notion review | Desktop chat + Notion | "Push it to Notion" | A Notion page with images for you to comment on |
| 4. Sync back | Desktop chat, folder connected | "Sync back" | Accepted edits in the doc; every code block as a real file in the folder; handoff.md |
| 5. Code development | Terminal or desktop Code tab | claude -n <topic>-build, then "Read handoff.md and continue" | Svelte components, passing checks, an updated handoff.md |
Stages 2 to 4 started as a one-way push and were later upgraded in the pipeline skill to a two-way sync. Edits and comments on the Notion page sync back into the Claude doc, and changes in the Claude doc are pushed to the Notion page again, so the two copies never drift apart before the code is built from them.
The handoff moment, step by step
- In the desktop chat, at the end of stage 4, say: "Sync back, write the code files into the project folder, and write a handoff.md for the Svelte build."
- Check the folder has what the terminal needs (commands below).
- Commit:
git add -A && git commit -m "sync: <topic> study guide". - Start the build session:
claude -n <topic>-build, then "Read handoff.md. Turn the study guide into a Svelte page under src/routes/guides/<slug>, reusing the diagram components." - When the page renders and checks pass, ask Claude Code to update
handoff.md, then commit. - To review visually, move the session into the desktop Code tab with
/desktopand use the preview pane to look at the page. - Back in the desktop chat, ask for the next study guide, or for review notes on this one.
cd ~/Projects/yverge-lab
ls content/guides/<slug>/ # notes and code from the sync
cat handoff.md # goal, decisions, next steps
git status # see what changed
The folder paths are suggestions; use the layout your project already has.
Pitfalls and troubleshooting
Most handoff problems come from the wrong folder, a stale note, or two sessions writing at once.
| Symptom | Likely cause | Fix |
|---|---|---|
| Claude Code doesn't know about the project | Started outside the project folder | cd into the folder and run claude again; /memory should list CLAUDE.md |
| Claude Code ignores a CLAUDE.md rule | The rule is vague, or conflicts with another file | Make it specific and checkable; run /memory to find conflicting files |
A rule vanished after /compact | It was only said in conversation, or lives in a nested CLAUDE.md | Move it into the project-root CLAUDE.md, which is re-read after /compact |
| Changes from one side disappeared | Both sides edited the same file | Commit before every switch; use a worktree for parallel coding |
| You hit a usage limit sooner than expected | Desktop and terminal draw from one shared budget | Pause one side; check /usage |
| Unexpected API charges | ANTHROPIC_API_KEY is set in your shell | Unset it, then /login with your plan account |
/desktop says it isn't available | API-key sign-in, a third-party provider, or an unsupported platform | Sign in with your Claude subscription, on macOS or x64 Windows |
Desktop's /resume doesn't list your session | It's still open in a terminal, or it's an SSH, WSL or cloud session | Close it in the terminal first; use a local session |
FAQ
Can the terminal read my desktop chat history? No. Chat conversations and Claude Code sessions are separate. Anything the terminal needs must be written to a file first.
Can I continue a desktop Code tab session in the terminal? Not as the same conversation: the docs say a desktop-app session resumes in the desktop app. Use handoff.md. If you want one session to move both ways, start it in the terminal, because a CLI session can go to Desktop and back.
Do I need the CLI installed to use the Code tab? No. The desktop app includes Claude Code. Install the CLI only if you want claude in a terminal.
Will two sessions on the same project break things? Only if they edit the same files. Different folders or separate worktrees are safe.
Should handoff.md go into git? Yes for a solo project: its history becomes a log of decisions. On a shared repo, use CLAUDE.local.md or a gitignored notes folder for anything personal.
Command library
Every command and file used in this playbook, in one place.
| Command or file | What it does | Where you run it |
|---|---|---|
claude -n <name> | Starts a named session you can resume by name | Terminal, inside the project folder |
claude --continue | Reopens the most recent session in this folder | Terminal |
claude --resume / claude --resume <name> | Opens the session picker, or a named session | Terminal |
/desktop | Moves the current terminal session into the desktop Code tab | Inside a terminal session |
claude --desktop --resume <session-id> | Opens a specific CLI session in Desktop | Terminal (v2.1.285+) |
/resume | Picks up a CLI session from inside Desktop | Desktop Code tab, local session |
/init | Generates a starting CLAUDE.md from your code | Claude Code, either surface |
/memory | Lists the CLAUDE.md and rules files loaded | Claude Code, either surface |
/usage | Shows how much of your shared plan budget is used | Claude Code |
/login | Switches sign-in to your Claude plan | Claude Code |
claude --worktree <name> | Starts an isolated git worktree for parallel work | Terminal |
handoff.md | The note each side leaves for the other | Project folder |
CLAUDE.md | Rules loaded at the start of every Claude Code session | Project root |
Rules to remember
- Running both at once is fine; editing the same files at once is not.
- One plan, one usage budget: the desktop app and the terminal share it.
- Conversations don't travel between Chat and the terminal; files do.
- Leave a
handoff.mdbefore every switch, and read it first after one. - Stable rules go in
CLAUDE.md; this week's plan goes inhandoff.md. - Commit before you switch.
- To move one coding session both ways, start it in the terminal and use
/desktop. - Check
/memorywhenever Claude seems to have forgotten the project.
Sources
- Use Claude Code Desktop: Coming from the CLI, parallel sessions, worktrees
- Get started with the desktop app
- Manage sessions
- CLI reference
- CLAUDE.md and auto memory
- What's new, week 35 2026: resume terminal sessions in Desktop
- Use Claude Code with your Pro or Max plan (shared usage limits)
If you're working out where AI fits in your business, book a 30-minute diagnostic.