REST Resource: thumbnails

Resource: ThumbnailDetails

Identifies different thumbnail image sizes associated with a YouTube resource.

  • A resource's snippet.thumbnails property contains the thumbnail images available for that resource, keyed by image size (default, medium, high, and so on).
  • Different resource types support different thumbnail sizes and define different dimensions for the same size name. For example, the default thumbnail is 120px wide and 90px tall for a video resource, and 88px wide and 88px tall for a channel resource.
  • Resources of the same type can expose different thumbnail sizes depending on the resolution of the original image or video. For example, higher resolution videos or custom thumbnails can support standard, maxres, fhd, qhd, or uhd images.
  • Each thumbnail object has width and height properties, though these dimensions might not be returned for every resource (for example, channel search results return only url).
  • If an uploaded thumbnail image doesn't match the required dimensions, YouTube resizes it without changing its aspect ratio. For standard videos, the image isn't cropped and might include black bars to fill the frame. For YouTube Shorts, custom thumbnail images are center-cropped to a 9:16 portrait aspect ratio (up to 2160px wide and 3840px tall).
JSON representation
{
  "default": {
    "url": string,
    "width": integer,
    "height": integer
  },
  "medium": {
    "url": string,
    "width": integer,
    "height": integer
  },
  "high": {
    "url": string,
    "width": integer,
    "height": integer
  },
  "standard": {
    "url": string,
    "width": integer,
    "height": integer
  },
  "maxres": {
    "url": string,
    "width": integer,
    "height": integer
  },
  "uhd": {
    "url": string,
    "width": integer,
    "height": integer
  },
  "fhd": {
    "url": string,
    "width": integer,
    "height": integer
  },
  "qhd": {
    "url": string,
    "width": integer,
    "height": integer
  },
  "shortsAspectRatio": {
    "url": string,
    "width": integer,
    "height": integer
  }
}
Fields
default

object

The default thumbnail image. For a video (or a resource that refers to a video, such as a playlist item or search result), this image is 120px wide and 90px tall. For a channel, this image is 88px wide and 88px tall.

default.url

string

The thumbnail image's URL.

default.width

integer (uint32 format)

The thumbnail image's width in pixels.

default.height

integer (uint32 format)

The thumbnail image's height in pixels.

medium

object

A higher resolution version of the thumbnail image. For a video (or a resource that refers to a video), this image is 320px wide and 180px tall. For a channel, this image is 240px wide and 240px tall.

medium.url

string

The thumbnail image's URL.

medium.width

integer (uint32 format)

The thumbnail image's width in pixels.

medium.height

integer (uint32 format)

The thumbnail image's height in pixels.

high

object

A high resolution version of the thumbnail image. For a video (or a resource that refers to a video), this image is 480px wide and 360px tall. For a channel, this image is 800px wide and 800px tall.

high.url

string

The thumbnail image's URL.

high.width

integer (uint32 format)

The thumbnail image's width in pixels.

high.height

integer (uint32 format)

The thumbnail image's height in pixels.

standard

object

A higher resolution version of the thumbnail image than the high resolution image. This image size is available for some videos and other resources that refer to videos, such as playlist items or search results. This image is 640px wide and 480px tall.

standard.url

string

The thumbnail image's URL.

standard.width

integer (uint32 format)

The thumbnail image's width in pixels.

standard.height

integer (uint32 format)

The thumbnail image's height in pixels.

maxres

object

A high resolution (720p) version of the thumbnail image. This image size is available for some videos and other resources that refer to videos, such as playlist items or search results. This image is 1280px wide and 720px tall.

maxres.url

string

The thumbnail image's URL.

maxres.width

integer (uint32 format)

The thumbnail image's width in pixels.

maxres.height

integer (uint32 format)

The thumbnail image's height in pixels.

uhd

object

The ultra-high resolution (4K) version of the thumbnail image. This image size is available for some non-Shorts videos; YouTube generates at most one of fhd, qhd, or uhd based on the highest resolution the source image supports. This image is 3840px wide and 2160px tall.

uhd.url

string

The thumbnail image's URL.

uhd.width

integer (uint32 format)

The thumbnail image's width in pixels.

uhd.height

integer (uint32 format)

The thumbnail image's height in pixels.

fhd

object

The full high definition (1080p) version of the thumbnail image. This image size is available for some non-Shorts videos; YouTube generates at most one of fhd, qhd, or uhd based on the highest resolution the source image supports. This image is 1920px wide and 1080px tall.

fhd.url

string

The thumbnail image's URL.

fhd.width

integer (uint32 format)

The thumbnail image's width in pixels.

fhd.height

integer (uint32 format)

The thumbnail image's height in pixels.

qhd

object

The quad high definition (1440p / 2K) version of the thumbnail image. This image size is available for some non-Shorts videos; YouTube generates at most one of fhd, qhd, or uhd based on the highest resolution the source image supports. This image is 2560px wide and 1440px tall.

qhd.url

string

The thumbnail image's URL.

qhd.width

integer (uint32 format)

The thumbnail image's width in pixels.

qhd.height

integer (uint32 format)

The thumbnail image's height in pixels.

shortsAspectRatio

object

The Shorts aspect ratio (9:16) version of the thumbnail image. This image size is available for YouTube Shorts that have a custom thumbnail set. Its dimensions depend on the uploaded image, up to 2160px wide and 3840px tall.

shortsAspectRatio.url

string

The thumbnail image's URL.

shortsAspectRatio.width

integer (uint32 format)

The thumbnail image's width in pixels.

shortsAspectRatio.height

integer (uint32 format)

The thumbnail image's height in pixels.

Methods

set

Uploads a custom video thumbnail to YouTube and sets it for a video, including YouTube Shorts.