Reference

Every BrowserCode URL, parameter and accepted value.

Every URL that BrowserCode accepts, with its parameters and their values. All URLs are relative to https://browsercode.io. The formats on this page are stable.

URLs

PathOpens
/ideThe JavaScript template picker and clone field.
/ide?framework=<id>A JavaScript template. See /ide.
/ide#<project>A shared JavaScript project.
/ide/github/<owner>/<repo>/tree/<ref>/<dir>A cloned GitHub repo. See /ide/github.
/javaThe Java example picker.
/java?example=<name>A Java example. See /java.
/java#<project>A shared Java project.
/agentsThe agent picker.
/agents/<tool>A coding agent. See /agents.
/embed?<parameters>The embeddable view. See /embed.
/embed/builderThe embed builder.
/llms.txtThis reference in plain text, for AI agents.

/ide

ParameterValue
frameworkA template id. Case and surrounding whitespace are ignored.
#<project>A project encoded by Share. Contains every file except lockfiles. Images are included as empty files.

Template ids

IdTemplateAlso accepted
viteVitevite.js, vitejs
reactVite + Reactreact.js, reactjs
svelteVite + Sveltesvelte.js, sveltejs
vueVite + Vuevue.js, vuejs, vue3
nextjsNext.jsnext, next.js
nuxtNuxtnuxt.js, nuxtjs
expressExpressexpress.js, expressjs

An unknown id opens the picker, with a message that names the rejected value.

/ide/github

/ide/github/<owner>/<repo>/tree/<ref>/<dir>
SegmentRequiredValue
ownerYesGitHub user or organization.
repoYesRepository name. Public repos only.
refYesBranch, tag or commit SHA. Branch names that contain / are not supported.
dirNoSubdirectory to boot from. Defaults to the repo root.

Boot behavior:

  • Package manager: pnpm if the package.json names pnpm in packageManager or has a workspace: dependency, or, when booting from the root, if pnpm-workspace.yaml exists. Otherwise npm.
  • Script: dev, or start if there is no dev. If neither exists, the boot stops with an error.
  • Native packages are overridden before install. See Native binaries.

/java

ParameterValue
exampleAn example name or id. Examples start on Java 25. An unknown value opens the picker.
#<project>A project encoded by Share. Contains the files, the Java version and the main class. Projects with no version run on Java 8.

Java examples

NameIdExampleGroup
helloworldjavaHello WorldBasics
guessjava-guessGuessing GameBasics
wordsjava-wordsWord CountBasics
calculatorjava-calculatorCalculatorBasics
swingjava-swingSwingGraphics
mandelbrotjava-mandelbrotMandelbrotGraphics
shapesjava-shapesShapesGraphics
lifejava-lifeGame of LifeGraphics
tictactoejava-tictactoeTic-Tac-ToeAlgorithms
sortingjava-sortingSortingAlgorithms
mazejava-mazeMazeAlgorithms
reflectionjava-reflectionReflectionLanguage features

Java versions

8, 11, 17, 21 and 25. helloworld has a classic variant for versions below 25, and shapes for versions below 21.

/agents

ToolAgentSign-in
claudeClaude CodeClaude account, with a pasted code. See Claude Code.
codexCodex CLIOpenAI API key. See Codex CLI.
piPi/login, or a provider API key. See Pi.

An unknown tool opens Claude Code.

/embed

ParameterValue
frameworkA template id. See /ide.
repoA GitHub URL or owner/repo, optionally followed by /tree/<ref>/<dir>. Without a ref, the main branch is cloned.
agentclaude, codex or pi.
runtimecheerpj for Java. framework then takes a Java example name or id, and defaults to helloworld.
viewComma-separated panes: files, search, editor, terminal, preview. Defaults to all. Unknown names are ignored.
apiKeyEmpty (apiKey=) for keyless mode. Other values are not supported. Ignored by Java embeds.
#<project>A shared project, in place of framework or repo. For a Java project, also pass runtime=cheerpj.

Rules:

  • The source is the first of these that is present: agent, runtime, the hash, repo, framework. With none, the express template boots.
  • A value that cannot be resolved shows an error instead of booting.
  • Below 768px wide, the panes become tabs. The embed opens on the preview, or on the Output tab for Java.
  • Agents open on the terminal. For them, view only controls the preview pane.

Host page requirements

EmbedRuntimeResponse headersiframe allow
runtime=cheerpjCheerpJNoneNone
All othersBrowserPodCross-Origin-Opener-Policy: same-origin
Cross-Origin-Embedder-Policy: require-corp
cross-origin-isolated

To use Share inside an embed in Chrome and Edge, also add clipboard-write to allow. See Embedding BrowserCode.

Runtime limits

BrowserPodCheerpJ
BrowsersChrome and Edge 137+, Firefox 153+, Safari 27+. Not iOS or iPadOS.All modern browsers, including mobile.
LanguagesNode.js 22, python3 (standard library only), prebuilt Rust programs.Java 8, 11, 17, 21, 25.
Toolsbash, git, npm, pnpm, curl, wget, tar, unzip, ripgrep, fd, coreutils.None. No shell.
Networknpm registry, GitHub and AI provider APIs only.—
Native binariesNot supported.Not applicable.
ConcurrencyOne session per agent per browser.One Java project per site.
Next
Self-hosting