Deepcrawl is now Lumar. Read more.
DeepcrawlはLumarになりました。 詳細はこちら

Audio element missing captions (WCAG Level A Issue)

Time and Media - Lumar Accessibility Issues Thumbnail
NULL NULL
 

What does this accessibility issue mean?

Issue summary: Audio element missing captions

All media elements on your website that have an audio component (including videos and stand-alone audio tracks) should have associated captions or subtitles to ensure accessibility compliance with WCAG standards. 

Captions provide a text alternative to audio files for users who are deaf are hard of hearing. 

Solution:

Audio and video elements should have an associated track element (<track>) with an HTML kind attribute of “captions” or “subtitles”.

Issue details

Lumar can help you find & resolve this website accessibility issue — & many others — on your own site. Speak to our team to get started with the platform.

Get a Lumar demo
 

Example HTML violation: Audio element missing captions (WCAG Level A Issue)

<!DOCTYPE html>
<html lang='en' class='no-js'>
  <head>
    <title>E-commerce Website</title>
  </head>
  <body>
    <audio controls>
      <source src="product_description.mp3" type="audio/mpeg">
    </audio>
  </body>
</html>

The issue with the above code is the lack of a track element for the audio element. The <track> element provides text captions and it's a way to add accessibility for people who are deaf and hard of hearing.

The issue can be solved by adding a captions track as shown below:

 

How to fix "Audio element missing captions (WCAG Level A Issue)" issue

<!DOCTYPE html>
<html lang='en' class='no-js'>
  <head>
    <title>E-commerce Website</title>
  </head>
  <body>
    <audio controls>
      <source src="product_description.mp3" type="audio/mpeg">
      <track src="captions.vtt" kind="captions" srclang="en" label="English">
    </audio>
  </body>
</html>

This corrected HTML code now includes a <track> element that points to captions in a WebVTT format (captions.vtt). This ensures that the audio content is accessible to the deaf community and complies with the accessibility rule identified by 'audio-caption'.

 
Digital Accessibility + SEO + Website Health

Build better online experiences — explore the full Lumar platform