MediaCapabilities

Baseline Widely available *

This feature is well established and works across many devices and browser versions. It’s been available across browsers since January 2020.

* Some parts of this feature may have varying levels of support.

Note: This feature is available in Web Workers.

The MediaCapabilities interface of the Media Capabilities API provides information about the decoding abilities of the device, system and browser. The API can be used to query the browser about the decoding abilities of the device based on codecs, profile, resolution, and bitrates. The information can be used to serve optimal media streams to the user and determine if playback should be smooth and power efficient.

The information is accessed through the mediaCapabilities property of the Navigator and WorkerNavigator interface.

Instance methods

MediaCapabilities.encodingInfo()

When passed a valid media configuration, it returns a promise with information as to whether the media type is supported, and whether encoding such media would be smooth and power efficient.

MediaCapabilities.decodingInfo()

When passed a valid media configuration, it returns a promise with information as to whether the media type is supported, and whether decoding such media would be smooth and power efficient.

Specifications

Specification
Media Capabilities
# media-capabilities-interface

Browser compatibility

desktop mobile
Chrome
Edge
Firefox
Opera
Safari
Chrome Android
Firefox for Android
Opera Android
Safari on iOS
Samsung Internet
WebView Android
WebView on iOS
MediaCapabilities
Chrome – Full support
Chrome 66 (Release date: 2018-04-17)
footnote Full support
Edge – Full support
Edge 79 (Release date: 2020-01-15)
footnote Full support
Firefox – Full support
Firefox 63 (Release date: 2018-10-23)
footnote Full support
Opera – Full support
Opera 53 (Release date: 2018-05-10)
footnote Full support
Safari – Full support
Safari 13 (Release date: 2019-09-19)
footnote Full support
Chrome Android – Full support
Chrome Android 66 (Release date: 2018-04-17)
footnote Full support
Firefox for Android – Full support
Firefox for Android 63 (Release date: 2018-10-23)
footnote Full support
Opera Android – Full support
Opera Android 48 (Release date: 2018-11-08)
footnote Full support
Safari on iOS – Full support
Safari on iOS 13 (Release date: 2019-09-19)
footnote Full support
Samsung Internet – Full support
Samsung Internet 9 (Release date: 2018-09-15)
footnote Full support
WebView Android – Full support
WebView Android 66 (Release date: 2018-04-17)
footnote Full support
WebView on iOS – Full support
WebView on iOS 13 (Release date: 2019-09-19)
footnote Full support
decodingInfo
Chrome – Full support
Chrome 66 (Release date: 2018-04-17)
footnote
footnote codecs string can contain any subset of optional parameters (should be all or none).
footnote Errors if codecs string contains unexpected characters (should evaluate string up to character).
Edge – Full support
Edge 79 (Release date: 2020-01-15)
footnote
footnote codecs string can contain any subset of optional parameters (should be all or none).
footnote Errors if codecs string contains unexpected characters (should evaluate string up to character).
Firefox – Full support
Firefox 63 (Release date: 2018-10-23)
footnote
footnote The webrtc value of the type option is named transmission.
footnote Before Firefox 101, decodingInfo() ignored codecs parameter options for av01 codecs (treating them as av1).
Opera – Full support
Opera 53 (Release date: 2018-05-10)
footnote
footnote codecs string can contain any subset of optional parameters (should be all or none).
footnote Errors if codecs string contains unexpected characters (should evaluate string up to character).
Safari – Full support
Safari 13 (Release date: 2019-09-19)
footnote Full support
Chrome Android – Full support
Chrome Android 66 (Release date: 2018-04-17)
footnote
footnote codecs string can contain any subset of optional parameters (should be all or none).
footnote Errors if codecs string contains unexpected characters (should evaluate string up to character).
Firefox for Android – Full support
Firefox for Android 63 (Release date: 2018-10-23)
footnote
footnote The webrtc value of the type option is named transmission.
footnote Before Firefox for Android 101, decodingInfo() ignored codecs parameter options for av01 codecs (treating them as av1).
Opera Android – Full support
Opera Android 48 (Release date: 2018-11-08)
footnote
footnote codecs string can contain any subset of optional parameters (should be all or none).
footnote Errors if codecs string contains unexpected characters (should evaluate string up to character).
Safari on iOS – Full support
Safari on iOS 13 (Release date: 2019-09-19)
footnote Full support
Samsung Internet – Full support
Samsung Internet 9 (Release date: 2018-09-15)
footnote
footnote codecs string can contain any subset of optional parameters (should be all or none).
footnote Errors if codecs string contains unexpected characters (should evaluate string up to character).
WebView Android – Full support
WebView Android 66 (Release date: 2018-04-17)
footnote
footnote codecs string can contain any subset of optional parameters (should be all or none).
footnote Errors if codecs string contains unexpected characters (should evaluate string up to character).
WebView on iOS – Full support
WebView on iOS 13 (Release date: 2019-09-19)
footnote Full support
configuration.keySystemConfiguration parameter
Chrome – Full support
Chrome 80 (Release date: 2020-02-04)
footnote Full support
Edge – Full support
Edge 80 (Release date: 2020-02-07)
footnote Full support
Firefox – Full support
Firefox 129 (Release date: 2024-08-06)
footnote Full support
Opera – Full support
Opera 67 (Release date: 2020-03-03)
footnote Full support
Safari – No support
Safari
footnote No support
Chrome Android – Full support
Chrome Android 80 (Release date: 2020-02-04)
footnote Full support
Firefox for Android – Full support
Firefox for Android 129 (Release date: 2024-08-06)
footnote Full support
Opera Android – Full support
Opera Android 57 (Release date: 2020-03-30)
footnote Full support
Safari on iOS – No support
Safari on iOS
footnote No support
Samsung Internet – Full support
Samsung Internet 13 (Release date: 2020-12-02)
footnote Full support
WebView Android – Full support
WebView Android 80 (Release date: 2020-02-04)
footnote Full support
WebView on iOS – No support
WebView on iOS
footnote No support
encodingInfo
Chrome – Full support
Chrome 101 (Release date: 2022-04-26)
footnote Full support
Edge – Full support
Edge 101 (Release date: 2022-04-28)
footnote Full support
Firefox – Full support
Firefox 63 (Release date: 2018-10-23)
footnote
footnote The webrtc value of the type option is named transmission.
Opera – Full support
Opera 87 (Release date: 2022-05-17)
footnote Full support
Safari – Full support
Safari 15.4 (Release date: 2022-03-14)
footnote Full support
Chrome Android – Full support
Chrome Android 101 (Release date: 2022-04-26)
footnote Full support
Firefox for Android – Full support
Firefox for Android 63 (Release date: 2018-10-23)
footnote
footnote The webrtc value of the type option is named transmission.
Opera Android – Full support
Opera Android 70 (Release date: 2022-06-29)
footnote Full support
Safari on iOS – Full support
Safari on iOS 15.4 (Release date: 2022-03-14)
footnote Full support
Samsung Internet – Full support
Samsung Internet 19 (Release date: 2022-11-01)
footnote Full support
WebView Android – Full support
WebView Android 101 (Release date: 2022-04-26)
footnote Full support
WebView on iOS – Full support
WebView on iOS 15.4 (Release date: 2022-03-14)
footnote Full support

Legend

Tip: you can click/tap on a cell for more information.

Full support
Full support
No support
No support
See implementation notes.

See also