为您的视频和音乐库自动转码
Snacks
Locally hosted. Lightly toasted.
An open-source, self-hosted transcoder for video and music libraries.
Scan, analyze, remux, encode, verify, and automate from one polished interface.
Website · Documentation · Offline guide · Downloads · Discord
Point Snacks at a video or music library, choose a preset, and let it do the repetitive work. It evaluates each file against the selected targets, skips media that is already suitable, and remuxes or transcodes everything else using the best available hardware path.
Automate the library
Watch folders, configurable scans, change detection, and transfer-safe processing keep new media moving without babysitting. Use the hardware already there NVIDIA, Intel, AMD, Apple VideoToolbox, and software encoders are detected and selected automatically.
Choose intent, not FFmpeg flags
Start with Space Saver, Balanced, Quality First, Max Compatibility, or a custom preset. See the entire pipeline Live progress, queue controls, savings analytics, health checks, and per-file logs stay in one interface.
Recover instead of giving up
Snacks validates outputs and can retry through progressively safer decode, subtitle, and software fallbacks. Scale beyond one machine Run standalone or distribute jobs across an authenticated cluster with automatic node discovery.
Take a closer look at the interface
Queue and onboarding. Current work, node status, and the next useful action.
Presets with an escape hatch. Start simple, then tune codecs, audio, subtitles, and file handling.
Distributed encoding. Configure standalone, coordinator, and worker nodes from the same interface.| Docker / NAS | Windows | macOS |
|---|---|---|
| QNAP, Synology, Unraid, and Linux hosts | Native installer for Windows 10/11 | Native Apple silicon DMG for macOS 11+ |
| Docker Hub · Setup guide | Download latest | Download latest |
Docker Compose quick start
services:
snacks:
image: derekshreds/snacks-docker:latest
container_name: snacks
network_mode: host
volumes:
- /path/to/media:/app/work/uploads
- ./snacks/config:/app/work/config
- ./snacks/logs:/app/work/logs
environment:
- ASPNETCORE_ENVIRONMENT=Production
- SNACKS_WORK_DIR=/app/work
- FFMPEG_PATH=/usr/lib/jellyfin-ffmpeg/ffmpeg
- FFPROBE_PATH=/usr/lib/jellyfin-ffmpeg/ffprobe
devices:
- /dev/dri:/dev/dri
restart: unless-stoppedThen open http://YOUR-SERVER-IP:6767.
/path/to/media to the library path on the host.devices when no Intel or AMD GPU is being passed through.privileged: true for /dev/dri access.See the complete Docker/NAS guide or the included deploy-compose.yml. Unraid users can start with unraid/snacks.xml.
[!IMPORTANT] Originals are not replaced unless Replace Original Files is explicitly enabled. For a first run, use Analyze, keep replacement disabled, and write to a separate output directory.
Advanced Video policies
Advanced Video is opt-in and disabled by default — upgrading never changes existing settings or decisions, and the layer does nothing until you enable it. The settings panel shows the decision flow as plain-language cards and previews what a staged policy would do to your entire library — per-rule file counts, disk usage, and measured results from completed encodes included — before you apply anything. Policies export and import as plain JSON files for sharing. See the in-app Advanced Video guide and the AV1 quality-policy example.
Hardware acceleration matrix
| Encoder | Docker / Linux | Windows | macOS |
|---|---|---|---|
| NVIDIA NVENC | CUDA | CUDA | — |
| Intel | VAAPI | QSV | — |
| AMD | VAAPI | AMF | — |
| Apple VideoToolbox | — | — | H.264 / HEVC |
| Software | x264, x265, SVT-AV1 | x264, x265, SVT-AV1 | x264, x265, SVT-AV1 |
Apple silicon can use VideoToolbox for AV1 decoding where supported, but FFmpeg does not currently expose an AV1 VideoToolbox encoder. Snacks therefore pairs hardware decoding with SVT-AV1 software encoding for that path.
For NVIDIA containers, install the NVIDIA Container Toolkit on the host and use the NVIDIA runtime. Intel and AMD hosts can pass /dev/dri into the container.
Automation, integrations, and API
Everything needed for unattended operation is configurable from the UI, environment variables, or HTTP:
SNACKS_SET_*SNACKS_SCAN_*SNACKS_INTEG_*X-Api-Key or a bearer token when sign-in is enabledHomarr can display Snacks in two ways:
| Option | What it provides | Connection and credential |
|---|---|---|
| Snacks compact tile | A read-only, responsive iFrame with Stats, Queue, and Workers tabs | Each viewer's browser connects to Snacks using a scoped iframe URL generated under Settings → Security → Iframe Access |
| Homarr Media Transcoding widget | Homarr's native transcoding UI backed by Snacks queue, worker, and savings data | The Homarr server connects to Snacks through a Tdarr integration, using a Snacks API key when authentication is enabled |
See the Homarr dashboard guide for complete setup steps, URL options, security notes, limitations, and troubleshooting for both choices.
Use the operations and API guide for examples, or inspect the hosted OpenAPI specification.
Build and contribute
The backend and web interface require the .NET 10 SDK.
dotnet restore Snacks.sln
dotnet test Snacks.sln
dotnet run --project Snacks/Snacks.csprojDesktop packages use the Electron wrapper in electron-app/:
build-installer.bat builds the Windows installer.build-mac.sh builds the Apple silicon DMG.run-electron-dev.bat starts the Windows desktop development environment.The build scripts package the backend, FFmpeg, and required runtime components into the desktop artifacts. See the repository's complete build and release guide for FFmpeg staging, Windows signing, macOS dylib bundling/notarization, Docker publishing, and release checks. The development and verification handbook contains the shorter day-to-day workflow.
Bug reports and focused pull requests are welcome through GitHub Issues.
Snacks is available under the MIT License.
Locally hosted. Lightly toasted.
暂无开放 Issues,或尚未同步最近议题。