How to Burn an SRT into a Video with FFmpeg
Use FFmpeg to hardcode a subtitle file into a video from the command line, with styling control.
Once you have a corrected SRT from Submagic or VEED, you do not always need to re-render inside those tools. FFmpeg can burn the subtitles into any video from the command line, which is ideal for automation and precise control. This guide covers the real commands.
- FFmpeg installed (verify with ffmpeg -version)
- A video file and a matching .srt in the same folder
- Comfort with a terminal
Step 1: Confirm FFmpeg is installed
Check the version first. On macOS you can install it with Homebrew if it is missing.
Step 2: Burn the SRT with one command
The subtitles filter draws the SRT onto each frame. This re-encodes the video, so it permanently bakes the captions in. The audio is copied through untouched.
ffmpeg -i input.mp4 -vf "subtitles=captions.srt" -c:a copy output.mp4Step 3: Control the look with force_style
You can override font, size, color, outline, and position using force_style, which takes ASS style keys. Colors are in &HBBGGRR hex order, which is reversed from normal RGB, so white is &HFFFFFF and yellow is &H00FFFF.
ffmpeg -i input.mp4 -vf "subtitles=captions.srt:force_style='FontName=Arial,Fontsize=24,PrimaryColour=&H00FFFFFF,OutlineColour=&H00000000,Outline=2,Alignment=2,MarginV=60'" -c:a copy output.mp4Step 4: Keep a soft subtitle track instead
If you want toggleable captions inside an MP4 rather than burned-in pixels, mux the SRT as a soft track with mov_text. Players that support it can switch captions on and off.
ffmpeg -i input.mp4 -i captions.srt -c copy -c:s mov_text -metadata:s:s:0 language=eng output.mp4Step 5: Batch a whole folder
For many clips, loop over files that share a base name with their SRT. This is where the command line beats clicking through a GUI.
for f in *.mp4; do
base="${f%.mp4}"
if [ -f "${base}.srt" ]; then
ffmpeg -i "$f" -vf "subtitles=${base}.srt" -c:a copy "out_${base}.mp4"
fi
doneResult: a folder of clips with matching SRTs is burned with consistent styling in a single scripted run, no editor required.
Watch related tutorials
20:30
15:18
14:02
13:27
11:48
16:20