Living Standard — Last Updated 21 September 2026
picture elementSupport in all current engines.
Support in all current engines.
source elements, followed by one img element,
optionally intermixed with script-supporting elements.[Exposed =Window ]
interface HTMLPictureElement : HTMLElement {
[HTMLConstructor ] constructor ();
};
The picture element is a container
which provides multiple sources to its contained img element
to allow authors to declaratively control or give hints to the user agent about which image resource to use,
based on the screen pixel density, viewport size, image format, and other factors.
It represents its children.
The picture element is somewhat different from the similar-looking
video and audio elements. While all of them contain source
elements, the source element's src attribute
has no meaning when the element is nested within a picture element, and the resource
selection algorithm is different. Also, the picture element itself does not display
anything; it merely provides a context for its contained img element that enables it
to choose from multiple URLs.
source elementSupport in all current engines.
Support in all current engines.
picture element, before the img element.track elements.