Captions provide your viewers synchronized text of the audio and non-speech elements of your video content. In addition, complimenting your video content with captions can have the following benefits:
- Improved video SEO
- Increased content retention
- Increased engagement with autoplay content
- Environment-independent content viewing
- Legal compliance
Captions can either be embedded in the video (embedded captions) or loaded from a separate file (side-loaded or sidecar captions). JW Player's players support both types of captions.
We strongly advise that you remotely self-host video content with embedded captions. If video content with embedded captions is uploaded to your JW Player account, the embedded captions may be removed during the encoding process.
The following table lists common caption formats that are supported.
|CEA-608 / CEA-708||Embedded||Used in videos that originally were on broadcast television|
Captions are included as part of the video content. These captions are styled according to the device's captions and subtitle settings that the viewer sets.
|WebVTT (.vtt)||Embedded or|
|Common format used for online video|
Captions can be embedded as part of a live stream or can be side-loaded as a separate file. WebVTT captions can include the caption, a description, and metadata information.
Your .vtt files should be saved using UTF8 encoding to prevent rendering issues.
|SubRip Text (.srt)||Side-loaded||Common format used for online video|
SubRip Text captions only include the caption. Neither description nor metadata information can be included.
|Timed Text Markup Language (.dfxp, .ttml, .xml)||Embedded (DASH only)||XML-based format used for online video|
Currently, JW Player supports ttml1 embedded in DASH streams.
JW Player supports embedded and side-loaded captions. The following sections explain how to add each type of caption to your video.
To add videos or streams with embedded captions to a player, use the following steps:
- Copy the URL of your video. The video must contain CEA-608, CEA-708, or in-manifest WebVTT captions.
- Define the
fileproperty of the
playlistobject with the URL of your video.
Do not add videos or streams with embedded captions to your JW Player library. The embedded captions tracks of the content may be removed during JW Player's video transcoding process.
- Within the
playlistobject for a specific video, create a
- Create an unnamed object within the
kindwith the value
- Add the caption track URL (
file) and language label (
- Repeat steps 2-4 for each additional caption track.
As an alternative to the previous steps, you can add your captions files in your JW Player dashboard.
In addition to using the configuration options of
setup() to add and customize captions, JW Player offers additional captions API calls that allow you to further customize your viewers' experiences.
Updated 7 months ago