Skip to content

Why can't I see or access content in my Sanity Studio?

0repliesLast updated: Nov 11, 2026

My Sanity Studio loads, but documents I know exist don't show up, or I can't open them. What are the usual causes, and how do I check whether the content is still in the dataset?
AI Update

In most cases the content is still in the Content Lake. The Studio is just looking somewhere else (a different project, dataset or workspace), doesn't know the document's type, isn't allowed to show it to you, or is showing a list or perspective that leaves it out. Go through the causes below in order. Use Vision to check what the dataset actually contains.

1. Wrong project ID or dataset

sanity.config.ts only requires projectId and dataset, so a typo or a wrong environment variable quietly points the Studio at a different place (configuration):

export default defineConfig({
  projectId: process.env.SANITY_STUDIO_PROJECT_ID!,
  dataset: process.env.SANITY_STUDIO_DATASET!,
})

Environment variables are replaced at build time. A .env.development or .env.local file can override the dataset on your machine, for example setting it to development while your content is in production (environments). Run npx sanity dataset list to see the datasets that exist, and also check sanity.cli.ts.

2. Wrong or hidden workspace

When defineConfig gets an array, each workspace has its own projectId, dataset, name, basePath and schema. You switch between them with the dropdown next to the Studio title. A workspace with hidden: true, or a hidden callback that returns true for your user, disappears from the menu, and going to its URL directly shows a not-found screen. hidden only affects what the UI shows. It does not control data access (workspaces).

3. Schema types removed or renamed

Changing the schema never changes or deletes existing content. If you rename or remove a type, documents with the old _type stay in the dataset, but the Studio no longer lists them. To find them:

*[_type == "oldTypeName"]{_id, _type, _updatedAt}

npx sanity documents validate also reports documents whose _type isn't in the schema. Patches and migrations can't change _type. You have two options:

Back up first with sanity datasets export (migrations).

4. Roles and permissions

Viewers can only read. Contributors can write drafts but can't publish. With custom roles on Enterprise plans, content permissions start at No access, and a content resource with a GROQ filter such as _type == "movie" limits which documents the role can see. A custom role that works with datasets also needs Project datasets: Read. Without it, requests fail with Unauthorized - User is missing required grant sanity.project.datasets/read. Permissions add up across roles, so check every role the user holds under Members at sanity.io/manage (roles). To test a specific permission:

curl "https://api.sanity.io/v2026-07-11/access/project/$PROJECT_ID/user-permissions/me/check?permissions=sanity.document.filter.update" \
  -H "Authorization: Bearer $USER_TOKEN"

(verifying permissions)

5. Custom Structure Builder

A custom structure decides which lists appear. Documents disappear from the lists when the structure:

(cheat sheet). To get the full list back for testing, use:

structureTool({structure: (S) => S.list().title('Content').items(S.documentTypeListItems())})

6. Drafts, published documents and perspectives

Drafts are separate documents with IDs like drafts.<id>. The published perspective leaves out drafts and documents that were never published, and it's the default from API version 2025-02-19. raw returns everything, and drafts returns drafts as if they were published (perspectives, drafts). In Vision, set the perspective to raw and run:

*[_id in path("drafts.**")]{_id, _type}

Vision sends requests with your Studio login. That's why drafts and private documents can show up there but not in a front end making unauthenticated requests (Vision lesson). For client queries, set the perspective explicitly:

createClient({projectId, dataset, apiVersion: '2025-02-19', useCdn: false, perspective: 'drafts'})

When to contact support

Contact Sanity support at sanity.io/help if all of these are true:

Include the project ID, the dataset and the document IDs.

Was this answer helpful?

Sanity – Build the way you think, not the way your CMS thinks

Sanity is the developer-first content operating system that gives you complete control. Schema-as-code, GROQ queries, and real-time APIs mean no more workarounds or waiting for deployments. Free to start, scale as you grow.

Related contributions