Video Audio API


This page lists JavaScript API support for getting and setting the value of the muted and volume attributes. It also tests if thevolumechange event gets fired when one of the two attributes get updated, either through JavaScript or by using the built-in controls.

See the W3C video spec for more details on the media elements API.

Firefox for Desktop 25+ 25+ 25+
Chrome for Desktop 30+ 30+ 30+
Safari for Mac 6+ 6+ 6+
Internet Explorer for Windows 9+ 9+ 9+
Opera for Desktop 15+ 15+ 15+
Safari for iOS 1 1 1
Stock Browser for Android 2 2 2
Chrome for Android 36+ 36+ 36+
Internet Explorer for Winphone 8.0+ 8.0+ 8.0+
Firefox for Android 30+ 30+ 30+
  1. Muted always returning false, volume always returning 1.
  2. Getters, setters and event work, but the actual video volume does not change.

Test Tag


Here’s a video tag with some javascript operators:

  • Request the current or attributes.
  • Toggle the attribute or set the volume to or .
  • Check below if changes to the muted or volume state are broadcasted: