
Grab your gear: The official Sanity swag store
Read Grab your gear: The official Sanity swag storeBased on the error you're describing, the Desk tool crash when creating a new document typically indicates a schema configuration issue. Since you mentioned you just created a new document type, here are the most common causes and solutions:
1. Missing Required Properties
Every document type needs at minimum a name and type property. Make sure your schema definition includes both:
defineType({
name: 'yourDocumentType',
type: 'document',
// ... other properties
})2. Invalid Field Definitions
Fields within your document also need proper name and type properties. According to Sanity's schema documentation, you should always use the defineField helper:
fields: [
defineField({
name: 'title',
type: 'string',
title: 'Title'
})
]3. Circular References or Invalid Types If you're referencing other document types or using custom types, make sure they're properly defined and don't create circular dependencies.
4. Validation Rules Errors If you've added validation rules, syntax errors in those functions can crash the Studio:
validation: (rule) => rule.required() // Make sure this is properly formattedCheck the browser console - Open your browser's developer tools and look for more specific error messages that will point to the exact line causing the issue
Temporarily simplify the schema - Comment out all fields except the bare minimum to see if the document type itself is the problem:
defineType({
name: 'yourDocumentType',
type: 'document',
fields: [
defineField({
name: 'title',
type: 'string'
})
]
})defineType and defineField from the correct package:import { defineType, defineField } from 'sanity'Check for typos - Common mistakes include misspelling property names like field vs fields, or using incorrect type names
Look for JavaScript syntax errors - Missing commas, unclosed brackets, or improper function syntax in validation rules or custom components
When you share the code you mentioned, look specifically for:
The browser console error will usually point to the exact line and property causing the crash, which will help narrow down the issue quickly!
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