Skip to content

compose_page

Compose a full HTML page from composable blocks and a style preset. Returns deployable HTML that can be passed directly to deploy.

Annotations

AnnotationValue
readOnlyHinttrue
destructiveHintfalse
openWorldHintfalse

Parameters

NameTypeRequiredDescription
stylestringYesStyle preset ID (e.g., noir, editorial, bold, fun). Use list_styles to see options.
blocksarrayYesOrdered list of blocks, rendered top to bottom. Each item has a blockId and optional props.
pageobjectNoPage-level metadata: title, description, favicon, lang, customCss, customJs.

Block item format

json
{
  "blockId": "hero-centered",
  "props": {
    "headline": "Welcome to Acme",
    "subheadline": "The future of deployment"
  }
}
  • blockId — required, from list_blocks
  • props — optional overrides. Only include what you want to change; defaults fill the rest.

Return format

Returns the complete HTML document in a code block. The HTML includes:

  • Full <!DOCTYPE html> document structure
  • Tailwind CSS CDN with custom color configuration
  • Google Fonts for the style's font families
  • All block HTML rendered in order
  • Any JavaScript from interactive blocks (FAQ accordion, countdown timer, forms) moved to the end of <body>

Example workflow

You: "Build me a landing page for my SaaS product called Beacon"

Claude:

  1. Calls list_styles to check available styles
  2. Calls list_blocks to check available sections
  3. Calls compose_page with:
    • Style: noir
    • Blocks: navbar-simplehero-centeredfeature-gridstats-rowpricing-three-tiertestimonials-cardsfaq-accordioncta-bannerfooter-full
    • Props customized with Beacon branding
  4. Calls deploy with the resulting HTML
  5. Shares the preview URL with you
  6. After your approval, calls publish to go live

Compose + deploy flow

list_styles → list_blocks → compose_page → deploy (preview) → publish (live)

This is the recommended workflow for building new pages. The compose_page output can also be modified by Claude before deploying — it's standard HTML.

Notes

  • Block ordering matters. Blocks render top to bottom in the order you specify. A typical page starts with navbar-simple, has a hero section, content blocks, and ends with a footer.
  • Partial overrides. You don't need to provide all props. Each block has defaults that are used for any prop you don't override.
  • Read-only. This tool generates HTML but doesn't deploy it. Use deploy to create a preview.
  • Form handling. Contact and waitlist blocks include in their forms, which is replaced with the real submission endpoint at publish time.
  • Custom CSS/JS. The page.customCss and page.customJs parameters let you inject additional styles or scripts into the page.

Deploy apps from conversation.