Embed a website in an MCP App changedconnectors/building/mcp-apps/embedded-sites
Nearest release: v2.1.332, published 5 hours after upstream edited the page. Shown because the two are within 24 hours of each other. Nothing here says the release caused the edit.
Upstream edited this page at 24 Nov 2026 17:03 UTC, give or take a minute or two: the time comes from Anthropic’s own sitemap rather than from a commit. This site recorded the change at 24 Nov 2026 17:07 UTC.
Upstream edited
Recorded here
Lines+8added
Lines−4removed
From line
167
where the diff opens
First seen
10 Nov 2026
this site's first read of the page
Recorded edits3to this page, all time
The whole hunk
from line 167, old and new numbered
/
from line 167
1671675. Ask Claude to open the view, and name your connector in the message
1681686. Allow the origins. Claude lists them in one of these places:
169169 * In the approval request for the tool that opens the view.
170 * In a review that you open from a line beside the view. If the permission setting in the message box is **Auto**, Claude can open the view without asking, so use the review.
170 * In a review that you open from a line beside the view. Use the review if no approval request lists them.
1711717. Confirm that the site renders in the view
172172
173173After you allow the origins, each one appears in `app.getHostCapabilities()?.sandbox?.csp?.frameDomains`. A view that opened before you allowed them receives an empty list.
from line 217
217217To sign a user in, pass a token from your server to the site through the view:
218218
2192191. On your server, add a tool that returns a short-lived, single-use token
2202. Set the tool's `_meta.ui.visibility` to `["app"]`, so that Claude can't call the tool
2202. Set the tool's `_meta.ui.visibility` to `["app"]`, which tells clients not to offer the tool to the model
2212213. In the view's script, call the tool with [`app.callServerTool()`](https://modelcontextprotocol.github.io/ext-apps/api/classes/app.App.html#callservertool)
2222224. From the view, send the token to the frame with `postMessage`, and set the target origin to the site's exact origin
2232235. On the site, exchange the token for a session
224224
225If your sign-in pages can be framed, you can show a sign-in form inside the frame instead.
225> [!WARNING]
226>
227> Don't rely on `visibility` to keep the token secret, in any client. A client can still let the model call the tool. The token can then enter the conversation, and anyone who gets it from there can exchange it for a session until it expires.
226228
229If your sign-in pages [can be framed](#allow-claude-to-frame-your-site), you can show a sign-in form inside the frame instead, so that no token passes through a tool.
230
227231## Device features in views that embed sites
228232
229233A view can't use the camera, the microphone, location, or clipboard write when Claude allows an origin for it. The sites that the view embeds can't use them either. The view loses these features even if you request them in `_meta.ui.permissions`.
from line 235
231235Plan for other views to lose the same features, including views that embed nothing:
232236
233237* **Directory connector**: when the listing allows an origin, plan for the connector's other views to lose them
234* **Custom connector**: where [embedded sites are available for custom connectors](#availability-of-embedded-sites-for-custom-connectors), plan for every view of the connector to lose them
238* **Custom connector**: plan for every view of the connector to lose them
235239
236240To see which features Claude granted a view, read `app.getHostCapabilities()?.sandbox?.permissions` in the view's script after `app.connect()` resolves. Each key is a granted feature. Claude on mobile doesn't report these features.
237241
No line in this hunk matches that.