Media Library

Configure Studio

Enable Media Library in your Studios.

The Media Library app allows content managers to share a central store of assets. You can enable Media Library integration with Studio to allow editors to select assets from the library for use in their documents, and upload new files and images to the library.

The Studio image selector interface with Media Library included.

In this guide, you'll learn to configure Studio to support integration with Media Library.

Prerequisites

Update the Studio configuration file

Enable Media Library support by setting mediaLibrary.enabled to true in your studio.config.ts file.

Optional: disable the default source

If you want to move completely to Media Library, you can disable the default media source. Use the form.images.assetSources configuration in your Studio config file (studio.config.ts) to filter the sources.

This example keeps Media Library and any custom sources, but removes the default media select option.

If you'd like to be more explicit and target the Media Library source, you can do so by comparing the source name with sanity-media-library-image-source.

Was this page helpful?