Publish pages from Claude, ChatGPT, or any AI tool
Sign up free to get your MCP connector URL and start publishing in seconds.
MCP Connector
Let AI assistants publish HTML pages directly to htmlpub
What is MCP?
The Model Context Protocol lets AI assistants use tools
The htmlpub MCP connector gives AI assistants like Claude the ability to publish, update, and manage HTML pages on your behalf. Instead of copying and pasting HTML, your AI assistant can publish directly to htmlpub.com with a single tool call.
One MCP connector works everywhere — Claude.ai, ChatGPT, Claude Code, and Claude Desktop. No API keys needed. Just sign in with your htmlpub account.
Setup
Connect your AI assistant in one step
Claude.ai
- Open Claude.ai and go to Settings
- Go to Connectors and click Add custom connector
- Enter the server URL:
https://mcp.htmlpub.com/mcp - Click Add, then sign in with your htmlpub account when prompted
ChatGPT
Requires a ChatGPT paid plan (Plus, Pro, or Business).
- Open ChatGPT and go to Settings (click your avatar) → Apps
- Enable Developer Mode under Advanced settings
- Click Create, name it "htmlpub", and enter the URL:
https://mcp.htmlpub.com/mcp - In a new chat, click + → More → enable htmlpub
Claude Code
Run this command in your terminal:
claude mcp add htmlpub --transport http https://mcp.htmlpub.com/mcpYou will be prompted to sign in with your htmlpub account on first use.
Claude Desktop
Add this to your claude_desktop_config.json:
{
"mcpServers": {
"htmlpub": {
"url": "https://mcp.htmlpub.com/mcp"
}
}
}On macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
On Windows: %APPDATA%\Claude\claude_desktop_config.json
Available Tools
All tools are available on every platform. Your AI assistant can use any of these tools after connecting.
Page Tools
create_page
Publish an HTML page. Auto-generates a slug by default, or provide a custom slug (Starter/Pro plans).
Parameters
| Name | Type | Description |
|---|---|---|
| html | string | The HTML content to publish |
| slug | string? | Custom URL slug (10-64 chars). Starter / Pro |
| title | string? | Page title (extracted from <title> tag if not provided) |
| siteId | string? | Optional site collection ID |
| password | string? | Password to protect the page (requires custom slug) |
update_page
Replace the full HTML content of a published page. For small changes, prefer edit_page.
Parameters
| Name | Type | Description |
|---|---|---|
| slug | string | Slug of the page to update |
| html | string | The new HTML content |
| title | string? | Updated page title |
edit_page
Apply targeted text replacements to a page without rewriting the full HTML
Parameters
| Name | Type | Description |
|---|---|---|
| slug | string | Slug of the page to edit |
| edits | array<{old_text, new_text, occurrence?}> | List of search/replace pairs. Each old_text must match exactly once unless occurrence is set. Use occurrence (1-indexed) to target a specific match when old_text appears multiple times. |
get_page
Get the HTML source of a published page, with options for compact overview or section-based retrieval
Parameters
| Name | Type | Description |
|---|---|---|
| slug | string | Slug of the page |
| compact | boolean? | Strip large inline content with preview placeholders (default: true) |
| section | string? | Extract a specific section at full fidelity (ignores compact): 'head', 'body', 'meta', 'style:N', 'script:N', 'svg:N' |
Use section='meta' for a structural overview, then section='style:0' or section='body' to fetch the part you need to edit.
list_pages
List all pages in your htmlpub account
No parameters. Returns a list of all your pages with their slugs, titles, URLs, and creation dates.
delete_page
Permanently delete a page
Parameters
| Name | Type | Description |
|---|---|---|
| slug | string | Slug of the page to delete |
Site Tools
create_site
Create a new site to group related pages together
Parameters
| Name | Type | Description |
|---|---|---|
| name | string | Display name for the site |
| slug | string | URL slug for the site (lowercase alphanumeric and hyphens) |
list_sites
List all sites with their page counts
No parameters. Returns a list of all your sites with names, slugs, page counts, and IDs.
Asset Tools
upload_asset
Upload a file (image, CSS, JS, or font) to a page
Parameters
| Name | Type | Description |
|---|---|---|
| slug | string | Slug of the page to upload to |
| filename | string | Filename with extension (e.g. 'logo.png') |
| base64Content | string | Base64-encoded file content |
| contentType | string | MIME type (e.g. 'image/png', 'text/css') |
Authentication
The MCP connector uses OAuth to authenticate with your htmlpub account. When you connect for the first time, you will be prompted to sign in and authorize access. No API keys are needed.
Your session stays active across conversations. If your session expires, you will be prompted to re-authorize.
Example Usage
What it looks like when an AI assistant uses htmlpub
Once connected, you can ask your AI assistant to publish pages naturally:
You say:
"Create a landing page for my photography portfolio and publish it to htmlpub"
The assistant will:
- Generate the HTML for your portfolio page
- Call
create_pagewith the HTML - Return the live URL where your page is published