The media object

The media object represents an object returned in a array. The media object is an abstract object that can represent the following object types:

The media object can also be returned by metafields of type file_reference (images and videos only). To learn more about accessing metafield values, refer to Accessing metafields.

You can use media filters to generate URLs and model-viewer tags so that media is rendered on the product page. To learn more about using product media in your theme, refer to Adding media to themes.

The media object has the following attributes. Some attributes unique to each media type are also available. For more information about these additional attributes, refer to the reference for each supported object type.