thumbnail populates a hidden thumbnailURL field on your upload documents, which the admin panel uses to show a preview image in list and edit views, and which is available in every API response.
payload.config.ts
- Images — uses the original file, or a specific size if
sizeNameis set. - Bunny Stream videos — uses the frame captured at
stream.thumbnailTime.
Options
Cache-busting with appendTimestamp
Thumbnails haveappendTimestamp on by default. When a file is replaced (for example, during image cropping), the timestamp changes and browsers fetch the new version instead of a cached copy. While it is enabled, the plugin also disables Payload’s cache tags for the thumbnail field, to avoid caching conflicts.
Opt out per config if you don’t want it:
Resizing with queryParams
Using a named image size
Custom transform function
thumbnail accepts the same URL-transform options as urlTransform. For full control over the thumbnail URL, provide transformUrl instead of appendTimestamp/queryParams — it replaces them, and you build the URL yourself. sizeName and streamAnimated still apply.
urlTransform.transformUrl (baseUrl, collection, filename, prefix, data) and returns the final URL string.