What is an SRT file? How to open, edit and fix it on Windows, Mac, Android and iPhone
SRT is the most widely used subtitle file format. It is stored separately from the video, and the player shows each line at the right time during playback. It is a plain text file that opens in Notepad, so once you know its layout you can fix or translate it yourself. This guide covers SRT from opening the file to the problems that come up most often. Turning subtitles that are burned into a video into an SRT file is covered separately in turning on-screen subtitles into an SRT file.
How an SRT file is built
Each subtitle takes four lines: a number, the display time, the text, and a blank line.
1
00:00:01,000 --> 00:00:03,200
Hello, today we are at the lake.
2
00:00:03,500 --> 00:00:06,000
The water is so clear.
- Time:
hours:minutes:seconds,milliseconds. Between seconds and milliseconds is a comma, not a period. With a period, some players cannot read the file. - Arrow: start and end are joined by
-->(two hyphens and a greater-than sign). - Blank line: there must be one empty line between subtitles. Without it, the next subtitle is shown stuck to the previous one.
- Styling: only bold
<b>, italic<i>and colour<font color="#ffff00">. Position and font cannot be set.
Opening and editing
- Windows: right-click the file → Open with → Notepad. When saving, keep Encoding set to UTF-8.
- Mac: open it in TextEdit. Choose Format → Make Plain Text before saving, so no formatting is added.
- Subtitle editors: for shifting times or splitting lines, Subtitle Edit (Windows, free) or Aegisub (Windows and Mac, free) are easier: they show the video next to the text so you can match the timing.
- Android: to watch with subtitles, open the video in VLC or MX Player and choose Subtitles → Load from file. If the video and the SRT have the same name (
trip.mp4andtrip.srt) in the same folder, they are picked up automatically. To edit, open the file in a text editor app from Google Play (for example Simple Text Editor). - iPhone: in the VLC app, put the SRT with the same name in the same folder as the video and the subtitles appear. The Photos app and the built-in player cannot read SRT.
Common problems
The subtitles do not show
- Check that the video and the SRT have the same name and are in the same folder.
- Check that the extension is
.srt. Saving from Notepad often produces.srt.txt. Turn on file extensions in the folder options and rename it. - Check that the times use commas, not periods, and that there is a blank line between subtitles.
- Platforms such as YouTube and Instagram need the SRT uploaded with the video; it cannot be attached to a video that is already online the way a player does. On YouTube, upload the SRT under Subtitles.
The text is garbled (□□□ or shapes like ê¹€)
This is an encoding problem. A subtitle file with characters outside English (accents, Korean, Japanese) must be saved as UTF-8 to display correctly on every device. Open it in Notepad, choose Save As, and set Encoding to UTF-8. Older files are sometimes saved in a regional encoding or ANSI; some players let you change the subtitle encoding in their settings instead.
The subtitles run ahead of or behind the sound
In VLC, the H (delay) and G (advance) keys move the subtitles by 0.05 s while playing. To fix the file itself, use Subtitle Edit → Synchronization → Adjust all times to shift everything at once.
"Do I need a codec?"
No. SRT is a text file and needs no codec. Advice about a "subtitle codec" usually means the player does not support SRT or the file names do not match. Try a player with built-in subtitle support, such as VLC.
Getting just the text out of an SRT
When you need only the spoken lines without the numbers and timings (a transcript, a translation brief, text for a blog post), there are two easy ways.
- Subtitle Edit: File → Export → Plain text. You can choose whether to merge the lines into one paragraph or keep one line per subtitle.
- Notepad / VS Code: open Replace, turn on regular expressions, and replace
^\d+\r?\n(the number lines) and^\d{2}:\d{2}:\d{2},\d{3} --> .*\r?\n(the timing lines) with nothing. Only the dialogue is left.
If what you have is subtitles drawn into the video picture rather than an SRT, see how to turn on-screen subtitles into an SRT file instead.
SRT compared with other subtitle formats
| Format | What it does | Where it is used |
|---|---|---|
| SRT | The simplest. Bold, italic and colour only | YouTube, most players and editing programs |
| VTT | Almost the same as SRT, with periods in the times. Made for web browsers | Video on websites, some platforms |
| ASS / SSA | Precise fonts, positions and effects | Fan subtitles, styled captions |
| SMI | An older format common in Korea; support is fading in current players | Old Korean subtitle files |
To convert between formats, open the file in Subtitle Edit and choose the format in Save As. SMI to SRT works the same way.
SRT and burned-in subtitles
An SRT file sits on top of the video, so it can be switched off or replaced at any time. Subtitles drawn into the picture itself (hard subtitles) have no separate text in the file. Soft vs hard subtitles explains how to tell them apart. If your own video has burned-in subtitles and you want them back as an SRT, read turning subtitles into an SRT file and then translating and re-subtitling.
Try it on your own video. Nothing to install, nothing uploaded.
Open workspace