Quickstart
Artifact Publisher turns a finished HTML document from your agent into a link anyone can open in a browser.
You need: An Artifact Publisher account (GitHub or Google), an MCP-capable agent, and one self-contained HTML file up to 10 MiB (25 MiB on the Max plan).
-
Account. Sign in at Your dashboard with GitHub or Google and create your workspace if needed. Free plan works. You do not need a publisher API key for the OAuth happy path.
-
Connect with OAuth. Prefer browser consent whenever the client supports it. Endpoint:
https://app.artifactpublisher.com/mcp(streamable HTTP). Full Directory and coding-agent steps: Connect with OAuth.Older installs that named the server
artifact-relaykeep working: the name is only a local label in your client.Open claude.ai/directory/artifact-publisher, choose Connect, complete consent, turn the connector on in chat, then run a publish prompt that calls
publish_artifact.URL only — no header. Complete browser consent when prompted (
claude mcp login artifact-publisherif list shows Needs authentication):Terminal window claude mcp add --transport http artifact-publisher \https://app.artifactpublisher.com/mcpStep-by-step: Publish HTML from Claude Code.
URL only — no bearer line. Codex starts an OAuth authorize URL after add:
Terminal window codex mcp add artifact-publisher --url https://app.artifactpublisher.com/mcpOr paste into
~/.codex/config.toml:[mcp_servers.artifact-publisher]url = "https://app.artifactpublisher.com/mcp"Step-by-step: Publish HTML from Codex.
Register the same endpoint as a remote HTTP MCP server and complete browser consent when the client offers it. See Connect with OAuth.
-
Publish. Ask your agent to call
publish_artifactwith yourhtml(titleoptional). The result includes the share link,https://app.artifactpublisher.com/artifact/<slug>. -
Send the link. By default it is
public: anyone with the link can open it, no account needed. It is not listed, and it asks search engines not to index it.
Advanced / headless: publisher API key
Section titled “Advanced / headless: publisher API key”Use a scoped publisher key when the client cannot do browser consent (Hermes, OpenClaw, CI, always-on agents, or clients that only send a custom header). Sign in at Your dashboard; it shows a publisher key once inside a ready-to-run Claude Code command. Later, published pages and keys are on the Artifacts tab.
The Cursor, Codex CLI, and Windsurf snippets read the key from an environment variable:
export ARTIFACT_PUBLISHER_KEY=<your-key>
Your dashboard gives you this command with your key filled in. Run it in a trusted terminal:
claude mcp add --transport http artifact-publisher https://app.artifactpublisher.com/mcp \ --header 'Authorization: Bearer <your-key>'Open Customize, then Connectors, Add, Custom and Web. Enter the URL, choose No sign in, and under
Request headers add header Authorization with value Bearer <your-key>. Request headers are in beta and not
available on every account yet. Auth settings can’t be edited after adding: remove and re-add to change
the key. Claude connects from Anthropic’s cloud, not your machine.
~/.cursor/mcp.json (or .cursor/mcp.json in a project):
{ "mcpServers": { "artifact-publisher": { "url": "https://app.artifactpublisher.com/mcp", "headers": { "Authorization": "Bearer ${env:ARTIFACT_PUBLISHER_KEY}" } } } }~/.codex/config.toml (shared with the Codex IDE extension and the ChatGPT desktop app):
[mcp_servers.artifact-publisher]url = "https://app.artifactpublisher.com/mcp"bearer_token_env_var = "ARTIFACT_PUBLISHER_KEY".vscode/mcp.json (VS Code prompts for the key):
{ "inputs": [{ "type": "promptString", "id": "ap-key", "description": "Artifact Publisher key", "password": true }], "servers": { "artifact-publisher": { "type": "http", "url": "https://app.artifactpublisher.com/mcp", "headers": { "Authorization": "Bearer ${input:ap-key}" } } } }In the Cascade panel, open the menu with three dots, then MCPs and Open MCP config file (mcp_config.json):
{ "mcpServers": { "artifact-publisher": { "serverUrl": "https://app.artifactpublisher.com/mcp", "headers": { "Authorization": "Bearer ${env:ARTIFACT_PUBLISHER_KEY}" } } } }Artifact Publisher for ChatGPT is in review with OpenAI. Until it's listed, ChatGPT Plus and higher plans can add it as a custom MCP server with this URL,
https://app.artifactpublisher.com/mcp, and sign in with OAuth. The ChatGPT desktop app also shares Codex's
~/.codex/config.toml, so you can add the server there as in the Codex CLI tab
(bearer_token_env_var = "ARTIFACT_PUBLISHER_KEY"), then restart the app (it then shows under Settings, MCP servers).
Most clients accept this shape. Some want "type": "http", and Windsurf uses serverUrl:
{ "mcpServers": { "artifact-publisher": { "type": "http", "url": "https://app.artifactpublisher.com/mcp", "headers": { "Authorization": "Bearer <your-key>" } } } }- Agent Skill: copy the portable Agent Skill so clients keep share-URL-first behaviour and never print keys or tokens.
- Revise:
update_artifact(passexpected_version) adds a version behind the same link. - Restrict:
set_artifact_accessswitches betweenpublic,private, andallowlist(unlistedstill works as an alias ofpublic). - Stop serving:
revoke_artifact. - Feedback (optional):
get_feedbackandreply_to_feedbackfor page and text-quote comments. - Guides: Publish HTML over MCP, publish HTML from Claude Code, publish HTML from Codex, share a Claude artifact without a Claude account, share a Claude Code artifact for review, host an HTML file and share a link, share Cursor or Codex CLI output as a web page, get reviewer comments into your agent, share a dashboard on an unlisted, revocable link and MCP servers that publish HTML, compared.
- Style (optional): add
<meta name="ap-theme" content="firn">to<head>for a built-in theme.
The artifact renders in a sandboxed iframe with no network access: inline all CSS, scripts, images, and data. Links the reader clicks still open, in a new tab.
Publisher key recovery
Section titled “Publisher key recovery”The publisher key token is shown only once. When calling POST /api/account/keys directly, you can include idempotency_key in the JSON body. Use 8 to 128 characters from [A-Za-z0-9_-]; omit the field rather than sending an empty string. Within 24 hours, retrying the same mint returns HTTP 409 with reason key_already_minted and the original key_id and token_hint, never the token. Reusing the key with different input returns conflict reason idempotency_key_reused. If you lost the token, revoke the original key and mint again with a fresh idempotency key.
Publishing has separate recovery through the Idempotency-Key HTTP header on the request carrying publish_artifact. See Retry recovery for its format, window and empty header behavior.