List thumbnails for a DriveItem

Important: APIs under the /beta version in Microsoft Graph are in preview and are subject to change. Use of these APIs in production applications is not supported.

Retrieve a collection of ThumbnailSet resources for a DriveItem resource.

A DriveItem can be represented by zero or more ThumbnailSet resources. Each thumbnailSet can have one or more thumbnail objects, which are images that represent the item. For example, a thumbnailSet may include thumbnail objects, such as common ones including small, medium, or large.

There are many ways to work with thumbnails on OneDrive. Here are the most common ones:

  • Enumerate available thumbnails for an item
  • Retrieve a single thumbnail for an item
  • Retrieve thumbnail content
  • Retrieve thumbnails for multiple items in a single request
  • Retrieve custom thumbnail sizes
  • Upload a custom thumbnail for an item
  • Determine if a custom uploaded thumbnail exists


One of the following permissions is required to call this API. To learn more, including how to choose permissions, see Permissions.

Permission type Permissions (from least to most privileged)
Delegated (work or school account) Files.Read, Files.ReadWrite, Files.Read.All, Files.ReadWrite.All, Sites.Read.All, Sites.ReadWrite.All
Delegated (personal Microsoft account) Files.Read, Files.ReadWrite, Files.Read.All, Files.ReadWrite.All
Application Files.Read.All, Files.ReadWrite.All, Sites.Read.All, Sites.ReadWrite.All

HTTP request

GET /me/drive/root:/{item-path}:/thumbnails
GET /me/drive/items/{item-id}/thumbnails
GET /groups/{group-id}/drive/items/{item-id}/thumbnails

Optional query parameters

This method support the $select OData query parameter to customize the response.

Request body

Do not supply a request body for this method.


If successful, this method returns a 200 OK response code and collection of ThumbnailSet objects in the response body.



Here is an example of the request.


Here is an example of the response.

HTTP/1.1 200 OK
Content-type: application/json

  "value": [
      "id": "0",
      "small": { "height": 64, "width": 96, "url": "https://sn3302files..."},
      "medium": { "height": 117, "width": 176, "url": "https://sn3302files..."},
      "large": { "height": 533, "width": 800, "url": "https://sn3302files..."}

Retrieve a single thumbnail

Retrieve the metadata for a single thumbnail and size by addressing it directly in a request.

HTTP request


Path parameters

Name Type Description
item-id string The unique identifier for the item referenced.
thumb-id number The index of the thumbnail, usually 0-4.
size string The size of the thumbnail requested. This must be one of the standard sizes listed.
HTTP/1.1 200 OK
Content-Type: application/json

  "width": 100,
  "height": 100,
  "url": ""

Retrieve thumbnail content

You can directly retrieve the content of the thumbnail by requesting the content property of the thumbnail.

HTTP request



The service responds with a redirect to the thumbnail URL.

HTTP/1.1 302 Found

Thumbnail content URLs are pre-authenticated and do not require an authorization header to be downloaded. These URLs are short lived and only valid for a few hours and should not be cached by apps.

Size values

This table defines the possible thumbnail sizes. While you can request any arbitrary thumbnail size, the defined values are likely to exist and return a value quickly:

Name Resolution Aspect Ratio Description
small 96 longest Original Small, highly compressed thumbnail cropped to a square aspect ratio.
medium 176 longest Original Cropped to the standard item size for the OneDrive web view.
large 800 longest Original Thumbnail with the longest edge resized to 800 pixels.


Note In OneDrive for Business and SharePoint:

  • Using these calls to expand the thumbnails collection will not work: GET /drive/root:/{item-path}?expand=children(expand=thumbnails) GET /drive/items/{item-id}/children?expand=thumbnails