media-preview
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@media-preview Show me the render output at ./out/demo.mp4"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Playable local media inside chat, without burning context. Most AI coding environments render .mp4, .wav, and .png outputs as dead file pills—while base64-inlining media into HTML artifacts blows past token caps and iframe CSP rules. media-preview streams local files straight from 127.0.0.1 into an MCP App view, keeping raw bytes completely out of LLM history.
Highlights
9:16 & 16:9 aware video players. Vertical Shorts and widescreen renders auto-fit inside inline chat height caps with a minimal overlay scrub bar, click-to-play, and fullscreen handoff that syncs playback timestamp on minimize.
72-bar interactive audio waveforms. Samples normalized peak bars directly from RIFF PCM/float WAV files in
< 1 mswith bounded memory, and decodes compressed formats (.mp3,.m4a,.ogg,.opus,.aac,.flac) via WebAudio in the client.Three-tier image presentation. Automatically chooses a video-sized showcase card for 1 image, an
82pxgallery strip for 2+ images, or right-aligned30pxmicro-thumbnails (mode: "peek") when an agent silently inspects frames mid-task.Session-resilient across restarts. Ships an app-only (
0-token)resolve_mediatool so reopening historical chats on a new ephemeral localhost port transparently re-hydrates every player.Hardened localhost streaming. Binds strictly to
127.0.0.1:0with a random 128-bit per-session token and serves only explicitly registered files.Zero npm dependencies. Runs out of the box on Node.js
>= 18with nonpm installor build step.
Related MCP server: snapWONDERS MCP
Native Desktop Lightbox
Clicking any image or video fullscreen button on Linux (Wayland/X11 with GTK4) launches a frameless translucent desktop overlay (src/modal.py) outside the narrow chat iframe—supporting scroll/pinch zoom up to 8×, drag pan, arrow-key gallery navigation, and live video timestamp sync. On macOS, Windows, or Linux setups without GTK4, media-preview detects availability via a startup handshake and falls back automatically to its built-in inline modal.
Installation
Google Antigravity
Clone directly into your Antigravity plugins directory:
git clone https://github.com/JustBipin/media-preview.git ~/.gemini/config/plugins/media-previewAntigravity discovers plugin.json, mcp_config.json, and the bundled agent workflow rules (rules/AGENTS.md) automatically—no build or install step required. Toggle or manage it anytime at customization://media-preview.
Any MCP Apps Host (mcp_config.json)
Works with Claude Desktop and any client implementing MCP Apps (ext-apps):
{
"mcpServers": {
"media-preview": {
"command": "node",
"args": ["/absolute/path/to/media-preview/src/server.mjs"]
}
}
}Optional: Linux GTK4 Overlay Packages
To enable the native desktop overlay outside the chat iframe on Linux:
# Ubuntu / Debian
sudo apt install python3-gi gir1.2-gtk-4.0 gstreamer1.0-gtk4
# Fedora
sudo dnf install python3-gobject gtk4 gstreamer1-plugin-gtk4
# Arch Linux
sudo pacman -S python-gobject gtk4 gst-plugin-gtk4Tool Reference
preview_media
Parameter | Type | Default | Description |
|
| required | Absolute paths or |
|
|
|
|
|
|
| Loop video or audio playback (useful for seamless Short loop checks). |
|
|
| Autoplay on load (muted on video per browser policy). |
Smoke Test
Verifies MCP stdio JSON-RPC framing, ui:// resource delivery, WAV RIFF peak extraction, open_modal path validation, and HTTP 206 Partial Content streaming:
npm testLicense
Available Tools
3 toolsopen_modalOpen Native Overlay ModalC
App-only helper to launch a frameless translucent desktop modal outside the chat iframe.
Inputs: mode (required), paths (required), loop, startTime, +1 more.
preview_mediaInline Media PreviewB
Render an inline video player (9:16 or 16:9), waveform audio player, or image filmstrip directly inside chat for local media files.
Inputs: paths (required), loop, mode, autoplay.
resolve_mediaRe-bind Media Stream URLsB
App-only helper to refresh localhost stream URLs when reopening historical chats.
Inputs: paths (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 3 tools
The three tools target distinct actions: launching a modal, rendering inline media, and refreshing stream URLs. However, open_modal and preview_media both involve displaying media, which could cause some confusion about when to use the external modal versus inline preview.
All tool names follow a clear verb_noun snake_case pattern: open_modal, preview_media, resolve_media. The convention is consistent and predictable.
Three tools is well-scoped for a focused media preview helper server. Each tool has a distinct purpose and no obvious redundancy.
The surface covers inline preview, modal launch, and URL resolution for historical chats. A minor gap exists around modal lifecycle (e.g., no close_modal) or media discovery/cleanup, but core workflows are supported.
Maintenance
Related MCP Connectors
Generate AI images, videos, music, SFX & speech in any AI assistant. Results appear inline in chat.
User-owned files and explicit AI Memories for authorized assistants with scoped access.
Host files from coding agents; stage on a branch and attach to GitHub PRs.
Persistent file storage for AI agents. Save files over MCP, get a link a human can open.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceProvides local, offline transcription, keyframe extraction, OCR, and pre-publish review of audio, video, and image files, enabling AI agents to see and hear media without cloud or API keys.52 npmApache 2.0

snapWONDERS MCPofficial
AlicenseAqualityCmaintenanceA locally-run server that lets an AI assistant hide files inside photos or videos, reveal concealed content, perform forensic analysis of images and videos, and convert media between formats. It reads input and writes output directly on the user's own machine, so files never need to be handed off through a separate client.474 PyPIMIT- AlicenseNot gradedqualityCmaintenanceEnables coding agents to inspect, transcribe, compress, and analyze images, video, and audio locally without loading heavy media into the main context, using subscription-backed workers and caching to avoid extra API costs.23 PyPIMIT
- AlicenseNot gradedqualityCmaintenanceEnables users to open generated HTML pages, PDFs, Office documents, and images straight from chat cards or a side-pane file list using their OS default application, or to choose another installed app via an Open With dropdown. Also reveals files in Finder or File Explorer, tracks recent outputs across conversations, and blocks risky executable launches.1MIT