Knowledge Base

What Is Start Time?

start-time

What does it mean when your file carries a field called Start Time? Read on to find out what it stands for, and why the value for Start Time can even turn out to be negative.

Start Time is the point on a file's internal clock where a stream is meant to begin playing. In most files that point is simply zero, but it does not have to be, and the value tells you where the very first frame or the very first audio sample belongs in time.

Which files carry it and where the value comes from

Start Time matters most in video files such as MP4, MOV, AVI, MKV and the MPEG transport streams that TV recordings arrive in, though audio files carry it too. A file holds several streams - picture, sound, sometimes subtitles - and each one gets its own start time, alongside a start time reported for the file as a whole.

The value is written by the program that assembled the file: the encoder, the recorder or the camera. It is not something a person sets.

The same information appears in a second form, usually labelled PTS, short for Presentation Time Stamp. Start Time is given in seconds, while the start PTS counts ticks of the stream's own clock, whose length is set by a companion field called Time Base. Both mark the same moment.

What the value looks like

Times are in seconds, normally printed with several decimal places:

  • 0.000000 - the ordinary case, the stream starts at the beginning
  • 0.021333 - a small offset of a few hundredths of a second
  • 1.400000 and larger - common in broadcast recordings, where the clock carries on from the incoming stream rather than restarting at zero
  • a negative value, meaning the stream is marked as beginning slightly before the file's zero point

Small offsets and negative values are usually not a fault. Compressed audio codecs need a short run-up of samples before they produce real sound, and that lead-in has to be accounted for somewhere; the offset in the start time is how the file records it, so that a player can discard it and still keep the sound lined up with the picture. It does not mean any frames are missing.

Why it matters

The practical importance of this field is synchronisation. If the picture and the sound in a file declare different start times, a player that reads and honours both keeps them together, while a tool that ignores them plays the sound out of step by exactly that offset. Lip sync that is out by a fraction of a second, with no obvious cause, very often traces back to a start time somewhere in the file.

It matters for editing too. Cutting, joining or re-wrapping a file discards or rewrites these timestamps, which is why a clip trimmed from a recording can come out with subtitles that drift, or why a cut lands a moment away from where you set it. A non-zero start time also explains why two programs can disagree about how long a file is, since one may measure to the last timestamp while the other subtracts the start.

The field carries no personal information of any kind.