# Share architecture diagrams as private HTML · Stacktree

Source: https://stacktr.ee/share-architecture-diagrams

[Skip to content](#main) [Stacktree](/)[Developers](/developers)[Agents](/agents)[Docs](/docs)[Use cases](/use-cases)[Pricing](/pricing)[Blog](/blog)[Dashboard](https://app.stacktr.ee)[Sign in →](https://app.stacktr.ee)      By [ Steve Smith ](/about) · Founder, Stacktree  ·  Last updated July 2, 2026          use case

#  Share an architecture diagram as private HTML.

   Mermaid, D2, Excalidraw, PlantUML, draw.io, hand-coded SVG — all render as HTML. Upload to Stacktree, gate to your team, send the link. Reviewers open it without logging in, and the agent that drew it can replace it in place when the design evolves.

  [ Get started free ](https://app.stacktr.ee/?join=1&from=seo_share_architecture_diagrams)   install npx stacktree-install
Copy
     No card · 3 pages free · about a minute

##  How do you share an architecture diagram with your team privately?

Render the diagram to a standalone HTML file — Mermaid Live, D2 export, Excalidraw export, or wrap a plain SVG in a minimal HTML shell — and upload it to Stacktree. The link is private by default; add an email-domain gate for stronger access control. Agents can publish directly via the MCP server, and call `update_site` to swap the diagram under the same URL when the design changes.

## Diagrams that work out of the box

  - Mermaid. Use Mermaid Live → Export HTML, or render server-side with @mermaid-js/mermaid-cli.
 - D2. d2 input.d2 output.svg → wrap the SVG in a one-line HTML file.
 - Excalidraw. Export → "Embed HTML" → save the file.
 - PlantUML / Graphviz. Render to SVG, wrap in HTML.
 - draw.io / diagrams.net. File → Export As → HTML.
 - Hand-coded SVG. Wrap in <!doctype html><svg>…</svg>.

## The agent path

 If your agent is already drawing the diagram (Claude Code, Cursor, Codex), let it publish too:

```
`You: "Draw the auth flow as Mermaid and publish it as a Stacktree gated to @yourco.com"

Agent:
  1. wrote auth-flow.html
  2. publish_html(file: "auth-flow.html") → https://stacktr.ee/p/...
  3. set_email_gate(slug: "...", domain: "yourco.com")`
```

## Replace-in-place for evolving designs

 Architecture changes. Instead of sending a new link every time, the agent calls `update_site` with the same slug — the diagram updates under the URL anyone has bookmarked. The Slack message linking to it picks up the new version on refresh.

## What this replaces

  - Confluence pages with embedded screenshots that go stale.
 - "Latest diagram is in this Slack thread" → wrong; it's in that thread.
 - Pasting Mermaid source into PRs and hoping the reader has a Mermaid plugin.
 - Sending a PNG screenshot that loses interactivity and pixelates on retina.

FAQ

## Frequent questions

     How do I share an architecture diagram with my team without using Confluence? +  Render the diagram to a self-contained HTML file (Mermaid Live, D2 export, Excalidraw export, or a hand-coded SVG inside a minimal HTML wrapper) and upload to Stacktree. The link is private by default; add an email-domain gate for stronger access control.   Which diagram formats work? +  Anything that exports to standalone HTML or SVG. Confirmed: Mermaid, D2, Excalidraw, PlantUML, draw.io, Graphviz, hand-coded SVG, and Claude Code's output of any of the above. Plain SVG works wrapped in a tiny HTML shell.   Can the agent render and publish the diagram for me? +  Yes. Ask Claude Code or Cursor to "draw the architecture as Mermaid and publish it as a Stacktree" — the agent emits the HTML, calls `publish_html`, and hands you back the URL.   What about interactivity (zoom, pan, node clicks)? +  Embedded JS works because Stacktree serves the HTML file as-is. Mermaid + d3 + cytoscape.js based diagrams all keep their interactivity.   Can the diagram update without me sending a new link? +  Yes — call `update_site` with the same slug and the diagram swaps under the same URL. Anyone who bookmarked it sees the new version on refresh.   How does this compare to Lucidchart or Figma? +  Lucidchart and Figma are full editing surfaces with comments, multi-cursor, and version history. Stacktree is the read-only publish endpoint — useful when the diagram lives in code (Mermaid, D2) and you just need a viewable, gated URL for it.
Keep reading

## Related guides

   -  [ Share Jupyter notebooks Same primitive for analysis-style HTML. ](/share-jupyter-notebook-html)
-  [ Host AI-generated reports For agent-written analyses and writeups. ](/host-ai-reports)
-  [ Internal tool hosting When the artifact is a one-off utility. ](/internal-tool-hosting)
-  [ Publish from Claude Code Have the agent that drew it publish it too. ](/claude-code)

References

## Sources and further reading

   -  [ Mermaid — official docs ↗ The diagram-as-code tool most often used for shareable HTML. ](https://mermaid.js.org/intro/)
-  [ D2 — terrastruct ↗ A modern declarative diagram language with SVG output. ](https://d2lang.com)
-  [ Excalidraw — embedding docs ↗ Reference for Excalidraw exports embedded in HTML. ](https://docs.excalidraw.com/docs/codebase/json-schema)

##  Stop pasting Mermaid into Slack.

 One upload, one private URL, one source of truth for the diagram.

 [ Sign up free → ](https://app.stacktr.ee/?join=1&from=cta_share_architecture_diagrams)   install npx stacktree-install
Copy
       Private hosting for the HTML your agents make.

[](https://betalist.com/startups/stacktree?utm_campaign=badge-stacktree&utm_medium=badge&utm_source=badge-featured)[Featured on](https://devhunt.org/tool/stacktree)[](https://buildlist.io)[Get started free](https://app.stacktr.ee/?join=1)

## Product

- [Page video](/page-video)
- [Ask this page](/ask-this-page)
- [Client spaces](/client-spaces)
- [Templates](/templates)
- [Example deliverables](/examples)
- [Custom domains](/custom-domains)
- [Client feedback](/client-feedback-loop)
- [One-time links](/one-time-view-links)
- [See how pages get read](/page-engagement)
- [Made with Stacktree](/made-with)
- [Security](/security)
- [Watch the demo](/demo)

## Agents

- [All integrations](/agents)
- [Claude Code](/claude-code)
- [OpenAI Codex](/codex)
- [Cursor](/cursor)
- [Claude.ai connector](/claude-ai-connector)
- [Claude Cowork](/what-is-claude-cowork)
- [Meta Muse](/muse)
- [MCP server](/mcp-publish-html)
- [Deploy from Claude Code](/deploy-html-from-claude-code)
- [Skills](/skills)
- [Slack app](/slack)
- [n8n node](/n8n)
- [Agent payments (x402)](/x402)

## Alternatives

- [All comparisons](/alternatives)
- [Head-to-head comparisons](/compare)
- [Tiiny Host](/tiiny-host-alternative)
- [GitHub Pages (private)](/github-pages-private-alternative)
- [Vercel](/vercel-alternative-for-agents)
- [ngrok](/ngrok-alternative-for-html)
- [Display.dev](/display-dev-alternative)
- [Static.app](/static-app-alternative)
- [OpenAI Codex Sites](/openai-codex-sites-alternative)
- [here.now](/here-now-alternative)
- [Shippage](/shippage-ai-alternative)
- [Best private hosting](/best-private-html-hosting)

## Use cases

- [All use cases](/use-cases)
- [Share with clients](/share-with-clients)
- [Send a file to a client](/share-html-file-with-client)
- [Share Claude artifacts](/share-claude-artifacts)
- [Share Jupyter notebooks](/share-jupyter-notebook-html)
- [Host Storybook privately](/host-storybook-privately)
- [Architecture diagrams](/share-architecture-diagrams)
- [AI-generated reports](/host-ai-reports)
- [Internal HTML tools](/internal-tool-hosting)
- [Private HTML hosting](/private-html-hosting)
- [Vibe-coded page hosting](/vibe-coding-hosting)
- [Leave a website builder](/website-builder-migration)

## Learn

- [Blog](/blog)
- [Glossary](/glossary)
- [FAQ](/faq)
- [Where AI output should live](/where-ai-output-lives)
- [Agent-loop hosting](/agent-loop-hosting)
- [Why agents need a publish primitive](/blog/why-agents-need-a-publish-primitive)
- [MCP servers explained](/blog/mcp-servers-explained-for-developers)
- [What changed in the 2026-07 MCP spec](/blog/mcp-2026-spec-changes)
- [Sites in Codex explained](/blog/sites-in-codex-explained)
- [Private-by-default hosting](/blog/private-by-default-html-hosting)
- [An agent paid us $1 (x402)](/blog/agent-paid-to-provision-itself)
- [When a loop hits a paywall](/blog/loop-engineering-paywall)
- [Pricing](/pricing)
- [Self-host (new)](/self-host)
- [Changelog](/changelog)
- [Docs](https://stacktr.ee/docs)
- [About](/about)
© 2026 Stacktree · stacktr.ee

[Privacy](/privacy)[Terms](/terms)[Security](/security)[Dashboard](https://app.stacktr.ee)[npm](https://www.npmjs.com/package/stacktree-mcp)[Sitemap](/sitemap.xml)[llms.txt](/llms.txt)[API spec](/openapi.json)

---
Full markdown summary of the Stacktree marketing surface: https://stacktr.ee/llms-full.txt
