ffmpeg-mcp
The ffmpeg-mcp server gives AI assistants the ability to perform video and audio editing using FFmpeg through natural language commands, eliminating the need to remember complex command-line flags.
Get Video Metadata — Probe a file to retrieve stream info, codecs, duration, and technical details.
Extract Frames — Save frames as images, either evenly spaced, at a time interval, or one per second.
Extract Audio — Strip the audio track from a video and save it as a
.wavfile.Clip Video — Cut a sub-clip by specifying a start time and duration.
Crop Video — Crop to a region using width, height, and x/y offset parameters.
Scale Video — Upscale to 1080p, 2K, or 4K while preserving aspect ratio.
Make a GIF — Convert a video segment into an optimized GIF.
Overlay Image — Composite an image (e.g., logo/watermark) with control over position, opacity, scale, and timing.
Overlay Video — Place a looping video on top of another with positioning and scaling options.
Trim & Concatenate — Trim multiple clips and stitch them together into one video.
Normalize Clips — Batch-normalize multiple clips in parallel to a common resolution, frame rate, codec, and compression settings.
Concatenate with Transitions — Join clips with smooth xfade transitions (e.g., fade, wipeleft, dissolve, circlecrop, and more).
Provides tools for media processing including video metadata retrieval, frame and audio extraction, scaling, cropping, clipping, GIF creation, and video concatenation with transitions and overlays.
Click on "Install 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., "@ffmpeg-mcpextract the audio from recording.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.

ffmpeg-mcp 🎬⚡
Edit video and audio by just talking to your AI assistant.
ffmpeg-mcp is a Model Context Protocol server that puts the full power of FFmpeg behind a clean set of tools your LLM can call — clip, crop, scale, overlay, concatenate with transitions, extract frames/audio, make GIFs, and more. No command-line flags to memorize.
✨ Why ffmpeg-mcp?
FFmpeg is incredibly powerful and incredibly hard to remember. ffmpeg-mcp hands that power to your AI assistant so you can say what you want in plain English:
"Grab the first 10 seconds of
demo.mov, scale it to 1080p, slap my logo in the top-right corner, and turn it into a GIF."
…and the model orchestrates the right tools for you. Each tool is a small, validated Python function — easy to read, reuse, and extend.
🗣️ Natural-language video editing — works in any MCP client (Claude Desktop, Cursor, Cline, …)
🧱 12 focused tools — composable building blocks instead of one giant black box
✅ Input validation built in — paths are checked for existence, emptiness, and validity before FFmpeg runs
🧩 Hackable — add a new tool by writing one function and registering it
Related MCP server: FFmpeg MCP Server
🛠️ Available Tools
Tool | What it does | Key parameters |
| Probe a file for streams, codecs, duration, etc. |
|
| Save frames as images (evenly, by interval, or 1/sec) |
|
| Pull audio out to a |
|
| Upscale to |
|
| Crop to a region |
|
| Cut a sub-clip by start + duration |
|
| Turn a segment into an optimized GIF |
|
| Composite an image (logo/watermark) with timing & opacity |
|
| Overlay a (looping) video onto another |
|
| Trim multiple clips and stitch them together |
|
| Normalize clips to a common res/fps/codec (in parallel) |
|
| Concatenate clips with an |
|
?marks optional parameters.concat_clips_with_transitionsupports many transitions —fade,wipeleft,slideup,circlecrop,dissolve,pixelize,radial, and dozens more.
📦 Requirements
Verify FFmpeg is available:
ffmpeg -version🚀 Quick Start
1. Clone & install
git clone https://github.com/yubraaj11/ffmpeg-mcp.git
cd ffmpeg-mcp
uv sync --frozen2. Connect it to your MCP client
Point your client at the server using the snippets below. Replace /path/to/ffmpeg-mcp with the absolute path to your clone.
{
"mcpServers": {
"ffmpeg-mcp": {
"command": "uv",
"args": ["--directory", "/path/to/ffmpeg-mcp/ffmpeg_mcp", "run", "main.py"],
"env": { "PYTHONPATH": "/path/to/ffmpeg-mcp" }
}
}
}{
"mcpServers": {
"ffmpeg-mcp": {
"autoApprove": [],
"disabled": false,
"timeout": 60,
"command": "uv",
"args": ["--directory", "/path/to/ffmpeg-mcp/ffmpeg_mcp", "run", "main.py"],
"env": { "PYTHONPATH": "/path/to/ffmpeg-mcp" },
"transportType": "stdio"
}
}
}3. Restart your client and start editing
"Extract 5 evenly-spaced frames from
intro.mp4.""Make a 3-second GIF from
clip.movstarting at 12s.""Concatenate
a.mp4,b.mp4, andc.mp4with a 1-secondwipelefttransition between them."
Processed files are written under ffmpeg_mcp/processed_elements/.
🧰 Project Layout
ffmpeg_mcp/
├── main.py # MCP server entry point — registers all tools
├── services/ # one module per tool
├── configs/ # colored logging setup
└── exceptions/ # structured error messages
utils/ # validation decorators & helpersEvery tool returns either the output file path or a structured JSON error (status, error_type, message, time), so failures are easy for the model to read and recover from.
🤝 Contributing
Contributions are very welcome! Adding a tool is roughly:
Write a function in
ffmpeg_mcp/services/your_tool.py.Export it from
ffmpeg_mcp/services/__init__.py.Register it in
main.pywithmcp.tool(name_or_fn=your_tool).
Please run the linter before opening a PR:
uv run ruff check .Found a bug or have an idea? Open an issue — and if this project saves you from another ffmpeg man-page dive, consider leaving a ⭐.
📚 Built With
fastmcp— the MCP server frameworkffmpeg-python— Python bindings for FFmpegpydantic— data validationcolorlog— colored logs
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/yubraaj11/ffmpeg-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server