HTML Audio/Video DOMbufferedProperty
HTML Audio/Video DOM Reference Manual
Example
Get the first buffered range (part) of the video, in seconds:
myVid=document.getElementById("video1");
alert("Start: " + myVid.buffered.start(0)
+ " End: " + myVid.buffered.end(0));
alert("Start: " + myVid.buffered.start(0)
+ " End: " + myVid.buffered.end(0));
Try it Yourself »
Definition and Usage
The buffered attribute returns a TimeRanges object.
The TimeRanges object represents the user's audio/video buffered ranges.
Buffered ranges refer to the time ranges of buffered audio/video. If the user jumps around in the audio/video, multiple buffered ranges will be returned.
Browser Support
![]()
![]()
![]()
![]()
![]()
All major browsers support the buffered property.
Note:Internet Explorer 8 and earlier versions do not support this property.
Syntax
audio|video.buffered
Return Value
| Type | Description |
|---|---|
| TimeRanges Object | Represents the buffered portion of the audio/video. Properties of the TimeRanges object:
Note:the first buffer range'sIndexis 0. |
HTML Audio/Video DOM Reference Manualother extensions