Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

HTML DOM Video muted Property

Video muted property

Video Object Reference The Video object

Example

Turn off the sound of the video:

document.getElementById("myVideo").muted = true;

Try it »


Definition and Usage

The muted property sets or returns whether the video should be muted (sound turned off).

This property reflects

When the attribute is present, it describes the video output state as muted.

Note:


Browser support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the muted property

Note: Internet Explorer 8 and earlier IE versions do not support


Syntax

Return the muted attribute:

videoObject

.muted

Set the muted attribute:

videoObject

.muted=true|false

Attribute values

Value Description
true|false Specifies whether the sound of the video output is muted.
  • true - Indicates that the video's sound should be turned off.
  • false - Default. Indicates that the video's sound should be turned on.
  • |

    Technical Details

    Return Value: Boolean, returns true if the sound of the video output is muted, otherwise returns false.
    Default Value: false

    More examples

    Example

    Check whether the sound is turned off:

    var x = document.getElementById("myVideo").muted;

    x

    The output is:

    true

    Try it »


    Related pages

    HTML Reference Manual: HTML


    Video Object Reference The Video object