TL;DR Build
https://claude.ai/code?prompt=…&repositories=owner/repo(URL-encode the values), drop it on a ticket or a doc, and one click opens the cloud form ready to send.
This is not another way to open Claude Code on the web. It is how you wire it into the tools you already use: Linear, GitHub Issues, Notion, an internal dashboard. The page accepts query parameters and fills the new-session form before you type a word.
Result:
https://claude.ai/code?prompt=Fix%20the%20login%20bug&repositories=acme/webapp
Open that link while signed in with GitHub connected, and you see the prompt and the repo already selected. You only hit send.
How to use it
1. Build the URL with the minimum you need
Four parameters. All optional; combine them for what you want pre-filled.
| Parameter | Alias | What it fills |
|---|---|---|
prompt |
q |
Session input text |
prompt_url |
(none) | URL to fetch the prompt from (when it does not fit in the query). Ignored if prompt is also set |
repositories |
repo |
Comma-separated owner/repo list |
environment |
(none) | Name or ID of the cloud environment |
Every value must be URL-encoded. In the browser:
const base = 'https://claude.ai/code'
const params = new URLSearchParams({
prompt: 'Fix the flaky test in auth.spec.ts',
repositories: 'acme/webapp',
environment: 'Default',
})
const url = `${base}?${params.toString()}`
// https://claude.ai/code?prompt=Fix+the+flaky+test...&repositories=acme%2Fwebapp&environment=Default
In a shell:
python3 - <<'PY'
from urllib.parse import urlencode
print('https://claude.ai/code?' + urlencode({
'prompt': 'Fix the flaky test in auth.spec.ts',
'repositories': 'acme/webapp',
}))
PY
2. Turn it into a "Fix with Claude" button
In an issue tracker, a PR template, or a runbook:
[Fix with Claude](https://claude.ai/code?prompt=Reproduce%20and%20fix%20AUTH-204&repositories=acme/webapp)
In a script that receives the ticket body:
# ISSUE_BODY and REPO come from the webhook or your tracker's CLI
ENC=$(python3 -c "from urllib.parse import quote; import sys; print(quote(sys.argv[1]))" "$ISSUE_BODY")
echo "https://claude.ai/code?prompt=${ENC}&repositories=${REPO}"
If the prompt is too long for a query string, host it at a public URL (raw gist, internal asset with CORS) and use prompt_url instead of prompt. That URL must allow cross-origin requests; otherwise the browser cannot read it.
3. What this link does NOT do
- It does not auto-start the session. It fills the form; you press send (or you do not).
- It does not replace
claude --cloud. From the terminal, that flag is still the short path (cloud sessions from browser or terminal). - It is not the
claude-cli://protocol. That opens the local CLI in a repo. This opens the cloud web UI in the browser.
When the session is done and you want the work on your machine, teleport is still the bridge.
Reference
| You want… | Use |
|---|---|
| A short prompt in the link | prompt (or q) |
| A long / generated prompt | prompt_url (open CORS) |
| One or more repos | repositories=owner/a,owner/b |
| A specific environment | environment=NameOrId |
| Launch without the browser | claude --cloud "task" |
Official docs: Pre-fill sessions (web quickstart)
Requirements
- Pro, Max, Team, or Enterprise account (same base as Claude Code on the web)
- GitHub connected at claude.ai/code (or
/web-setupin the CLI) - Browser signed into Anthropic; otherwise you hit login first