How to Extract SUP Files from Blu-ray and MKV Sources
A practical guide to extracting PGS subtitle streams from Blu-ray discs and MKV containers using FFmpeg, MKVToolNix, and HandBrake — before converting to SRT.
Before you can convert PGS subtitles to SRT, you need a .sup file to work with. If you’re starting from a Blu-ray disc or an MKV file, this guide covers the main methods to extract the subtitle stream.
What You’re Actually Extracting
When you “extract SUP from Blu-ray,” you’re pulling out the PGS subtitle track embedded in the disc’s BDMV structure or inside an MKV container. The output is a .sup file — a standalone binary container holding all the subtitle display sets for that track.
Once extracted, you can run it through the free SUP to SRT converter to get an editable SRT file.
For a full explanation of the PGS format and why OCR is required, see Understanding PGS Subtitles.
Method 1: Extract from MKV with FFmpeg
FFmpeg is the most reliable tool for subtitle extraction and works on all platforms.
Check what subtitle tracks exist
ffprobe -v quiet -print_format json -show_streams input.mkv | grep -A5 "subtitle"
Or simpler:
ffmpeg -i input.mkv
Look for lines like:
Stream #0:2(eng): Subtitle: hdmv_pgs_subtitle
Stream #0:3(spa): Subtitle: hdmv_pgs_subtitle
The hdmv_pgs_subtitle codec tells you these are PGS tracks you can extract.
Extract a specific subtitle track
ffmpeg -i input.mkv -map 0:s:0 -c copy output.sup
0:s:0= first subtitle track of the first input file0:s:1= second subtitle track-c copy= stream copy (no re-encoding, preserves the original data exactly)
The output file will be a valid .sup file ready for OCR conversion.
Batch extract all subtitle tracks
ffmpeg -i input.mkv -map 0:s -c copy subtitle_%d.sup
This creates subtitle_0.sup, subtitle_1.sup, etc. — one file per subtitle track.
Method 2: Extract from MKV with MKVToolNix
MKVToolNix provides a graphical interface for MKV operations. It’s the easiest option if you prefer not to use the command line.
Using MKVToolNix GUI
- Open MKVToolNix and click “Open files”
- Select your
.mkvfile - In the Tracks panel, uncheck all tracks except the subtitle track you want
- Under Output, set the destination filename (e.g.,
subtitles.sup) - Click Start muxing
The output will be a .sup file containing just the extracted subtitle stream.
Using mkvextract (command line)
mkvextract tracks input.mkv 2:output.sup
Replace 2 with the actual track ID shown in mkvinfo or MKVToolNix’s track list. Track IDs start at 0 in some contexts and 1 in others — check the track listing first.
Method 3: Extract During Blu-ray Rip with HandBrake
HandBrake rips physical Blu-ray discs and can pass through PGS subtitle tracks into the output MKV.
Passthrough subtitles during rip
- Open HandBrake and select your Blu-ray source
- Go to the Subtitles tab
- Click “Add Track” and select the PGS subtitle tracks you want
- Set the Burn In option to No (passthrough, not hardcoded)
- Rip to MKV format
The resulting MKV will contain the PGS tracks as hdmv_pgs_subtitle streams. Then use FFmpeg or MKVToolNix to extract them as described above.
Note: HandBrake cannot directly output
.supfiles. It embeds PGS tracks inside the MKV container. You need a second extraction step.
Method 4: Extract Directly from Blu-ray with MakeMKV
MakeMKV is the standard tool for decrypting and extracting Blu-ray content. It creates MKV files with all original streams preserved.
- Insert the Blu-ray disc and open MakeMKV
- In the title list, expand the title you want
- Make sure subtitle tracks are checked in the stream list
- Click Make MKV
The output MKV will contain PGS subtitle tracks. Extract them using FFmpeg or MKVToolNix as shown above.
Identifying the Right Subtitle Track
A single disc may have many subtitle tracks — multiple languages, director’s commentary, SDH (for the hearing impaired), and forced subtitles. Before extracting, identify which track you want.
Using FFprobe
ffprobe -v quiet -print_format json -show_streams -select_streams s input.mkv
Look at the tags section of each stream for language (ISO 639-2 code like eng, spa, fra) and title fields.
Using MKVInfo
mkvinfo input.mkv
Lists all tracks with codec, language, and name metadata.
Understanding Track Numbering
FFmpeg uses stream specifiers to identify tracks:
0:s:0— first subtitle stream in the first file0:s:1— second subtitle stream in the first file
MKVToolNix uses track IDs which you can see in the GUI or via mkvinfo. These may differ from FFmpeg’s stream indices.
Always verify which track you’ve extracted by checking the output file size. A valid PGS stream for a 2-hour film is typically 2–15MB. A near-empty file (under 1MB) may indicate the wrong track was selected.
Verifying the Extracted SUP File
After extraction, verify the file before converting:
# Check file size — should be at least a few hundred KB for real content
ls -lh output.sup
# Check magic bytes — a valid SUP file starts with "PG" (0x50 0x47)
xxd output.sup | head -1
A valid PGS file begins with: 5047 (the ASCII codes for “PG”) in every segment header.
Now Convert to SRT
Once you have your .sup file, upload it to the online SUP to SRT converter:
- Drop the
.supfile onto the converter - Select the subtitle language from the dropdown
- Click Convert
- Download the resulting
.srtfile
All processing happens in your browser — no file is uploaded to any server. The converter uses Tesseract OCR to read each subtitle image and produce a standard SRT file with the original timestamps.
Troubleshooting
“File appears to be incomplete” — The SUP file may have been truncated during extraction. Try re-extracting with -c copy to ensure no re-encoding.
Empty or zero-byte output — You selected the wrong track. Check track IDs with mkvinfo or ffprobe and try again.
Wrong subtitles — Multiple languages exist. Use ffprobe to identify language tags and select the correct stream index.
OCR produces garbage — The wrong OCR language is selected. Match the language setting in Sup to Srt to the actual subtitle language.