Sanity GUI schema creation and auto-populating with mock/fake data?

6 replies
Last updated: Jan 28, 2026
I’m hoping to use Sanity as an earlier part of our design and prototyping workflow.
Are there any techniques or plugins folks would recommend to –

1. Create Sanity schemas via a GUI?
2. Populate a Sanity instance with example content based on the schema (similar to using Faker.js directives)?
Wish #1 would definitely be helpful in some circumstances, although not critical.

Wish #2 would be vital to exemplify a model, to better design against it.

How are others faking or mocking realistic dummy data in Sanity?
AI Update

Great questions about streamlining your prototyping workflow! Let me address both:

1. Creating Schemas via GUI

Unfortunately, there isn't a first-party or widely-adopted GUI schema builder for Sanity. The schemas are code-first by design, defined in TypeScript/JavaScript files. This approach gives you type safety, version control, and programmatic flexibility that visual builders typically can't match.

That said, you can make schema creation faster with:

  • VS Code Snippets - The official Sanity extension includes snippets for quickly scaffolding schemas
  • Templates - Many come with pre-built schemas you can adapt
  • Recipes - Reusable schema patterns for common use cases

The code-first approach actually becomes an advantage once you're comfortable with it - you can copy, modify, and generate schemas programmatically, which is harder with GUI builders.

2. Generating Mock/Seed Data

This is where @sanity-typed/faker really shines! It's exactly what you're looking for - it generates realistic mock data based on your schemas using Faker.js under the hood.

Here's how it works:

import { sanityConfigToFaker } from "@sanity-typed/faker";
import { base, en } from "@faker-js/faker";
import config from "./sanity.config";

const sanityFaker = sanityConfigToFaker(config, {
  faker: { locale: [en, base] }
});

// Generate a mock product document
const mockProduct = sanityFaker.product();

This will generate fully-typed mock documents with realistic data for all your fields - strings, arrays, objects, references, etc. Perfect for prototyping and testing!

Custom Mocks

You can also customize the generated data using customMock on your schema types to match your specific needs.

Other Approaches

If you need to actually seed your dataset (not just generate mocks in memory), you can:

The @sanity-typed/faker package is part of the @sanity-typed ecosystem by Shayan Hashimoto, which also includes typed clients and GROQ helpers - definitely worth exploring if you're working with TypeScript!

Show original thread
6 replies

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.

Was this answer helpful?