
Grab your gear: The official Sanity swag store
Read Grab your gear: The official Sanity swag storeBased on the documentation, I can see this is a common point of confusion! When you define a field with type: 'string' and a list of options in your schema, Sanity stores only the value, not the title/label.
The key thing to understand is that the title in list options is purely for the Studio UI - it's what editors see when selecting options, but it never gets saved to your database. Only the value is stored.
Here's an example schema:
{
name: 'status',
type: 'string',
options: {
list: [
{title: 'In Progress', value: 'in_progress'},
{title: 'Completed', value: 'completed'}
]
}
}When an editor selects "In Progress", your database stores "in_progress".
To display the title in your frontend, you have a few approaches:
const statusTitles = {
'in_progress': 'In Progress',
'completed': 'Completed'
}
const displayTitle = statusTitles[document.status]*[_type == "myDoc"] {
statusTitle: select(
status == "in_progress" => "In Progress",
status == "completed" => "Completed",
"Unknown"
)
}{
name: 'status',
type: 'object',
fields: [
{name: 'title', type: 'string'},
{name: 'value', type: 'string'}
]
}This is mentioned in the preview configuration documentation - titles in list options are display-only and not stored in the database. Most developers go with option 1 or 2 since it keeps your data clean and normalized.
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.
Content operations
Content backend


The only platform powering content operations
By Industry


Tecovas strengthens their customer connections
Build and Share

Grab your gear: The official Sanity swag store
Read Grab your gear: The official Sanity swag store