
Grab your gear: The official Sanity swag store
Read Grab your gear: The official Sanity swag storeGood news - there are several approaches depending on your plan level!
The most common way to separate environments is to use multiple datasets within the same Sanity project. You'd typically have separate datasets like development, staging, and production.
How it works:
development without affecting productionSetting this up:
In your sanity.config.ts, you can use environment variables to switch datasets:
export default defineConfig({
projectId: 'your-project-id',
dataset: process.env.SANITY_STUDIO_DATASET || 'production',
// ... rest of config
})Then each developer can set SANITY_STUDIO_DATASET=development locally, or you can have separate Studio deployments for each environment.
For schema changes during development: When you're actively changing schemas, each developer can either:
development dataset (content might get messy but that's okay)dev-alice and dev-bobIf you're on an Enterprise plan, Advanced Dataset Management offers "hot swapping" - you can create dataset aliases that seamlessly switch between datasets. This is perfect for testing migrations and CI/CD pipelines where you want to validate changes before promoting to production.
For early-stage projects with multiple developers:
development and productiondevelopment firstThe key insight is that schemas are code (they live in your repo), so you version control them like any other code. The datasets just hold the content that conforms to those schemas. When you change a schema, you're just deploying new code - the content in each dataset adapts to the new schema structure.
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