The problem: one webhook per document balloons deploy traffic
When a Sanity editor publishes ten blog posts in a row, the default webhook setup fires ten separate POST requests to your Next.js revalidate endpoint. Each triggers an ISR purge. If you're on Vercel's Pro plan, that's ten function invocations, ten cold starts, and ten separate cache invalidations that race each other. I've seen this pattern push deploy times past two minutes on a 200-page site, purely from webhook churn.
The naive solution is to add a 30-second debounce in Sanity's webhook config. That helps, but it doesn't solve the core issue: Next.js On-Demand Revalidation expects you to name every path or tag you want to purge. If your blog index depends on all posts, you end up either revalidating /blog once per post (redundant) or writing brittle logic to figure out which paths changed.
Use revalidateTag and a single Sanity webhook
Instead of per-document webhooks, I register one Sanity webhook that POSTs a _type and optional _id payload to a single Next.js route handler. The handler revalidates a tag, not a path. Here's the setup.







