HTML | DOM Video volume Property

The Video volume property is used for setting or returning the audio volume of a video.
The range of the values accepted by the Video volume property lies between 0.0 (silent) and 1.0 (loudest).


  • Return the volume property:
  • Set the volume property:
    videoObject.volume = number

Property Values:

  • 1.0: This is the highest volume. It is also the default value.
  • 0.5: It is used ti soecufy half volume.
  • 0.0: It is used to specify zero volume/ mute/ silent.

Return: The Video volume property returns a number which represents the volume of the video.

Below program illustrates the Video Volume property:
Example: Setting the video volume to 50%.





<!DOCTYPE html>
        DOM Video volume Property
<body style="text-align: center">
    <h1 style="color: green">
    <h2 style="font-family: Impact">
      Video volume Property
    <video id="Test_Video" 
        <source src="sample2.mp4" 
        <source src="sample2.ogg" 
    <p>To set the volume of the video 
      track to 50%, double click the 
      "Set Volume" button.</p>
    <p>To return the volume of the 
      video track, double click 
      the "Return Volume" button.</p>
    <button ondblclick="My_Video()">
      Set Volume
    <button ondblclick="R_Volume()">
      Return Volume
        var v = 
        function My_Video() {
            v.volume = 0.5;
        function R_Volume() {



  • Before clicking the button:
  • After clicking the button:

Supported Browsers: The browser supported by HTML | DOM Video volume Property are listed below:

  • Google Chrome
  • Internet Explorer
  • Firefox
  • Opera
  • Apple Safari


My Personal Notes arrow_drop_up

If you like GeeksforGeeks and would like to contribute, you can also write an article using or mail your article to See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.

Article Tags :
Practice Tags :

Be the First to upvote.

Please write to us at to report any issue with the above content.