Blog

Building a Static Site With Astro and Sanity
To build a static site with Astro and Sanity, keep Astro's default output: 'static', configure @sanity/astro with useCdn: false, and fetch
Dive Deeper
Common Sanity Mistakes and How to Fix Them
The most common Sanity mistakes are using the CDN where you need fresh data, fetching whole documents with ..., leaving slugs unvalidated, ship
Dive Deeper
How to Create a Custom Sanity Plugin
To create a custom Sanity plugin, wrap a piece of Studio configuration in definePlugin from the sanity package and add it to the plugins ar
Dive Deeper
How to Deploy Sanity Studio to the Web
The quickest way to deploy Sanity Studio is to run npx sanity deploy from your Studio folder. The CLI builds the Studio, asks you to choose a h
Dive Deeper
How to Embed Sanity Studio in a Next.js App
To embed Sanity Studio in a Next.js app, add a sanity.config.ts file at the project root with 'use client' at the top and a basePath such a
Dive Deeper
GROQ Cheat Sheet: Essential Queries for Beginners
A GROQ cheat sheet is a quick reference for the query patterns you use most in Sanity. Nearly every query follows the same shape: start with *
Dive Deeper