Issue with alt_text in Sanity Studio resolved by uploading an image
Based on the documentation, there are a few common reasons why alt_text might not be showing up in Studio:
1. The field isn't defined in your schema
The most common issue is that alt_text (or alt) needs to be explicitly added as a custom field in your image type definition. Images in Sanity don't automatically include an alt text field - you need to add it yourself:
{
name: 'image',
title: 'Image',
type: 'image',
options: {
hotspot: true
},
fields: [
{
name: 'alt',
title: 'Alt Text',
type: 'string',
description: 'Important for SEO and accessibility'
}
]
}2. Field name mismatch
Make sure you're using the correct field name. If you defined it as alt in your schema but are looking for alt_text, it won't appear. Check your schema definition to confirm the exact field name you used.
3. The field is hidden or has conditional logic
If you've added any hidden properties or conditional logic to your field definition, it might not be visible under certain conditions. Check if there are any hidden or readOnly configurations on the field.
4. Schema changes not reflected
After adding the field to your schema, make sure you've restarted your Studio dev server. Schema changes require a restart to take effect.
Once you've added the field properly to your schema, it will appear as an editable field when you click on the image in Studio, and you can query it alongside your image data using GROQ.
You can find more details about adding custom fields to images in the Image Type documentation and this guide on displaying images.
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.