claude-code - 💡(How to fix) Fix [ENHANCEMENT] Enable media playback in Cowork artifact sandbox (video/audio/HLS) [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#49182Fetched 2026-04-17 08:48:33
View on GitHub
Comments
0
Participants
1
Timeline
5
Reactions
0
Author
Participants
Timeline (top)
labeled ×5

Cowork artifacts block all outbound network access from the sandboxed iframe — including <video> elements, fetch(), XHR, and HLS.js streaming. This prevents any media-rich plugin from playing video or audio inline.

Error Message

| Test | Result | Error |

Root Cause

  • No AI platform currently supports inline video playback. This would be a first.
  • Unlocks an entire plugin category: video, audio, podcasts, live streams, music.
  • Industry pattern confirmed this week: Bitmovin (leading video player vendor) publicly demoed a "Bitmovin Player MCP" April 14-15 with the same goal — inline playback in Claude and ChatGPT. We are a Bitmovin Player customer and reproduced their setup with our license on a clean Cowork artifact; we hit the identical sandbox restrictions. The same blocker affects both Bitmovin's demo and our production plugin. This isn't vendor-specific.
  • Developers are already bypassing this unofficially. The "Claude Artifacts Unlocker" Chrome extension exists on the Chrome Web Store specifically to disable CSP in Claude artifacts. A scoped, per-plugin allowlist would be strictly better than users globally disabling CSP via browser extensions — and would remove the incentive for that entire class of extension.
  • Related requests: #22903 (real-time visual pipes), #12676 (native video file support), #29602 (sandbox network allowlist).

Fix Action

Fix / Workaround

Current Workaround

RAW_BUFFERClick to expand / collapse

Preflight Checklist

  • I have searched existing requests and this feature hasn't been requested yet
  • This is a single feature request (not multiple features)

Problem Statement

Summary

Cowork artifacts block all outbound network access from the sandboxed iframe — including <video> elements, fetch(), XHR, and HLS.js streaming. This prevents any media-rich plugin from playing video or audio inline.

Test Results

TestResultError
MP4 <video src="...">BlockedMedia load rejected by URL safety check
fetch() to public HTTPSBlockedFailed to fetch
HLS.js via CORS proxyBlockedmanifestLoadError (HTTP 0)
fetch() to localhostBlockedFailed to fetch
<iframe src="http://localhost:...">BlockedNo request received
Cloudflare tunnel (public HTTPS)BlockedFailed to fetch
Bitmovin Player v8 (licensed) loading HLSBlockedSOURCE_COULD_NOT_LOAD_MANIFEST

Note: <script src="https://cdnjs.cloudflare.com/..."> loads fine — libraries like HLS.js and Bitmovin Player initialize. But all runtime network access is blocked (fetch, XHR, video src, audio src, WebSocket), so no stream ever loads.

Why This Matters

  • No AI platform currently supports inline video playback. This would be a first.
  • Unlocks an entire plugin category: video, audio, podcasts, live streams, music.
  • Industry pattern confirmed this week: Bitmovin (leading video player vendor) publicly demoed a "Bitmovin Player MCP" April 14-15 with the same goal — inline playback in Claude and ChatGPT. We are a Bitmovin Player customer and reproduced their setup with our license on a clean Cowork artifact; we hit the identical sandbox restrictions. The same blocker affects both Bitmovin's demo and our production plugin. This isn't vendor-specific.
  • Developers are already bypassing this unofficially. The "Claude Artifacts Unlocker" Chrome extension exists on the Chrome Web Store specifically to disable CSP in Claude artifacts. A scoped, per-plugin allowlist would be strictly better than users globally disabling CSP via browser extensions — and would remove the incentive for that entire class of extension.
  • Related requests: #22903 (real-time visual pipes), #12676 (native video file support), #29602 (sandbox network allowlist).

Proposed Solution

Proposed Solutions

Any of these would solve it:

  1. Allowlisted domains per plugin — Plugins declare permitted media origins in their manifest (e.g., allowedMediaOrigins: ["*.akamaized.net"]). The sandbox permits <video>/<audio> to those domains only. Scoped, auditable, opt-in.

  2. Native media artifact type — A first-class video/audio component in the artifact system, like HTML/React artifacts today. The platform handles playback securely outside the sandbox.

  3. Relaxed sandbox for media elements only — Allow <video> and <audio> to load external sources while keeping fetch()/XHR restricted. Media elements consume content rather than exfiltrate data, making them lower risk.

Alternative Solutions

Current Workaround

Hand the stream URL to the OS (opens in VLC or default browser). Works, but defeats the purpose of inline playback in Cowork.

Priority

Critical - Blocking my work

Feature Category

MCP server integration

Use Case Example

  1. User asks Claude in Cowork: "Show me live news channels"
  2. MCP plugin returns channel data (name, logo, HLS stream URL)
  3. Claude generates an HTML artifact with a channel grid
  4. User clicks a channel - video plays inline in the artifact
  5. User asks "What else is on?" - Claude updates the artifact

Step 4 currently fails because the artifact sandbox blocks the video element from loading the HLS stream. Every other step works today.

Additional Context

Tested on Cowork (Claude Desktop, macOS), April 2026. HTML artifacts only — React artifacts can't load CDN scripts like HLS.js.

This blocker was also reproduced with a licensed Bitmovin Player v8 setup (Bitmovin publicly demoed a "Bitmovin Player MCP" the week of April 14-15, 2026). Same result: SOURCE_COULD_NOT_LOAD_MANIFEST — library loaded, license validated, every stream source blocked by sandbox network policy.

Related issues: #22903 (real-time visual pipes), #12676 (native video file support), #29602 (sandbox network allowlist).

extent analysis

TL;DR

Implementing an allowlisted domains per plugin feature would likely resolve the issue of blocked outbound network access from sandboxed iframes.

Guidance

  • The proposed solution of allowlisted domains per plugin seems to be a viable approach, where plugins declare permitted media origins in their manifest, and the sandbox permits <video>/audio> to those domains only.
  • To verify the effectiveness of this solution, test the plugin with a specific allowlisted domain and check if the media element can load the external source.
  • Another possible solution is to implement a native media artifact type, which would handle playback securely outside the sandbox, but this might require significant changes to the existing architecture.
  • A relaxed sandbox for media elements only could also be considered, allowing <video> and <audio> to load external sources while keeping fetch()/XHR restricted.

Example

No specific code example is provided as the issue is more related to the architecture and design of the system rather than a specific code snippet.

Notes

The solution should be carefully evaluated to ensure it does not introduce any security vulnerabilities, as the current sandbox restrictions are in place to prevent potential security risks.

Recommendation

Apply the allowlisted domains per plugin workaround, as it seems to be the most straightforward and secure solution, allowing for scoped and auditable control over media origins.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix [ENHANCEMENT] Enable media playback in Cowork artifact sandbox (video/audio/HLS) [1 participants]