html tutorial - Track <track> tag in HTML - html5 - html code - html form

track tag in html

Learn html - html tutorial - track tag in html - html examples - html programs

  • <track> tag is used for defining subtitles, captions and other content for audio and video tags.
  • <track> tag is particularly specifying text track for media tags.
  • It supports Global and event attributes.

Syntax for <track> tag:

<track src=”source file”>

Differences between HTML 4.01 and HTML5 for <track> tag

HTML 4.01

  • HTML4 does not supports <track> tag.


  • The track tag is new to HTML5.

Sample Coding for <track> tag:

Tryit<!DOCTYPE html>
<html >
        <title>Wikitechy track tag</title>
        <h2>HTML track tag with example</h2>
            <video width="320" height="240" controls>
            <source src="hibiscus.mp4" type="video/mp4">
            <track src="subtitles.vtt" kind="subtitles" srclang="en" 

Code Explanation for <track> tag:

code explanation for track tag

  1. <video> tag will display the movie clips or any other video file.
  2. <source> tag is given for the file path of the video file.
  3. <track> tag is defined the subtitles for the video file.
  4. “src” attribute used to define the location of the track file.
  5. “kind” attribute is used to specifies the file as “subtitles”.
  6. The “srclang” attribute specifies the language of the track text data as “en”.
  7. The “label” attribute used to specify the title of the track file as “english”.

Browser Support for <track> tag:

18.0 10.0 31.0 6.0 15.0

Related Searches to track tag in html

Adblocker detected! Please consider reading this notice.

We've detected that you are using AdBlock Plus or some other adblocking software which is preventing the page from fully loading.

We don't have any banner, Flash, animation, obnoxious sound, or popup ad. We do not implement these annoying types of ads!

We need money to operate the site, and almost all of it comes from our online advertising.

Please add to your ad blocking whitelist or disable your adblocking software.