Search w3schools.com:

SHARE THIS PAGE

HTML Audio/Video DOM pause() Method

HTML audio Tag Reference HTML Audio/Video DOM Reference

Example

A video with play and pause buttons:

var myVideo=document.getElementById("video1");
function playVid()
  {
  myVideo.play();
  }
function pauseVid()
  {
  myVideo.pause();
  } 

Try it yourself »

Definition and Usage

The pause() method halts (pauses) the currently playing audio or video.


Browser Support

Internet Explorer Firefox Opera Google Chrome Safari

The pause() method is supported in all major browsers.

Note: This method is not supported in Internet Explorer 8 and earlier.


Syntax

audio|video.pause()


HTML audio Tag Reference HTML Audio/Video DOM Reference

Your suggestion:

Close [X]

Thank You For Helping Us!

Your message has been sent to W3Schools.

Close [X]