Discussion about estimating billing and preventing surprise charges with Vercel and Sanity hosting services

14 replies
Last updated: May 31, 2023
So a few months ago, I pitched Sanity to the agency I contract with because they do a lot of Wordpress stuff, but we would like to get more into the JAM stack ecosystem. I've only built one next.js app for production. It's fairly large and complex, but it's an authenticated system with only a few users and it's self-hosted, so it doesn't get a lot of traffic and I'm not the one managing the server so I don't know what the costs are. With the project coming up, we have complete freedom, so we have decided to host it through vercel for the next.js frontend and sanity as the backend. This first project with Sanity is going to be very simple. It's basically a marketing site, but I have no idea how much traffic it will get. Currently, they don't get traffic because they don't have a website. Everyone talks about how generous the free tier is with both Vercel and Sanity. Even the next plan up isn't so bad. $20 for Vercel...$100 for Sanity (is that right?) Some people have said Vercel and Sanity are super expensive. I'm assuming the free tier is going to be plenty for this project, but I really don't know. What questions to we need to answer as a team to build an accurate monthly billing estimate? And at what point do these services go from super affordable/free to super expensive? I've heard some horror stories about traffic spikes resulting from spam/attackers that have caused people's bills to skyrocket to hundreds and even thousands of dollars in a single month. Obviously nobody wants that for a simple marketing site. Are these real concerns? Can this actually happen? If so, what do I need to do as the developer to prevent something like that from happening? I really don't want to be in the situation where the agency comes to me and says hey you said this was going to be pretty cheap (~$120/month for hosting) and now we have a bill for $2k...
AI Update

Great question! This is exactly the kind of due diligence you should be doing before pitching a stack to an agency. Let me break this down for you.

Sanity Pricing (2025)

Based on Sanity's official pricing page, here's what you need to know:

Free Plan:

  • Unlimited API CDN requests (the fast, cached reads your marketing site will mostly use)
  • 200,000 API requests per month (uncached reads/writes)
  • 10GB bandwidth
  • 10GB assets storage
  • 10,000 documents
  • Up to 20 users
  • 2 datasets (public only)

Growth Plan: $15 per user/month (not $100 - that might be outdated info)

  • Everything in Free, plus:
  • Private datasets
  • 5 permission roles (vs 2 on Free)
  • AI Assist
  • Comments, Tasks, Content Releases
  • Scheduled Publishing
  • Pay-as-you-go for overages

Overage pricing (when you exceed Free tier limits):

  • API CDN requests: Very generous, typically not a concern
  • API requests: Charged per million over quota
  • Bandwidth: Charged per GB over quota
  • The pricing page has these specific rates

For a simple marketing site with proper caching (which Next.js + Vercel do automatically), you'll almost certainly stay on the free tier. The unlimited API CDN requests are key here - that's what visitors hitting your site will use.

Vercel Pricing

Vercel's free Hobby tier is genuinely generous for small projects, but the Pro plan is $20/month per user (you had this right). The key limits to watch:

  • Bandwidth on free tier
  • Image optimization credits
  • Serverless function execution time
  • Build minutes

Questions to Answer as a Team

  1. Expected traffic volume: How many page views per month realistically?
  2. Content update frequency: How often will content editors make changes?
  3. Media/asset strategy: How many images? What sizes? Will you use Sanity's image CDN or another service?
  4. Number of editors: How many people need access to Sanity Studio?
  5. Build frequency: How often will the site rebuild on Vercel?
  6. ISR/caching strategy: Will you use Next.js ISR (Incremental Static Regeneration) to minimize API calls?

When Costs Escalate

Sanity: Costs jump when you:

  • Need more than 20 users (requires Growth plan at $15/user/month)
  • Exceed 200k API requests/month (but with proper caching, unlikely for a marketing site)
  • Store massive amounts of assets (10GB is actually quite a lot)
  • Need private datasets or advanced features

Vercel: Costs escalate with:

  • High bandwidth usage (most common culprit)
  • Excessive image optimization
  • Many serverless function invocations
  • Lots of builds

The Horror Stories - Are They Real?

Yes, but they're preventable. Here's what causes them:

Bot/DDoS traffic: This is the big one. Malicious traffic can spike your bandwidth and serverless function calls.

How to protect yourself:

  1. Implement rate limiting: Use Vercel's Edge middleware or services like Cloudflare
  2. Add bot protection: Vercel has built-in bot protection on Pro plans; consider Cloudflare for free tier
  3. Set up monitoring and alerts: Both Vercel and Sanity let you set usage alerts
  4. Use proper caching: Next.js ISR or SSG (Static Site Generation) means most requests never hit Sanity
  5. Enable Vercel's DDoS protection: Included in Pro plans
  6. Configure Vercel spending limits: You can set hard caps on Pro plans to prevent runaway bills

Best practices for a marketing site:

  • Use Static Site Generation (SSG) or ISR for most pages
  • Set revalidation periods appropriate to your content update frequency (e.g., every hour or day)
  • Optimize images before uploading to Sanity
  • Use Sanity's image pipeline with proper sizing parameters
  • Implement proper CDN caching headers
  • Consider adding Cloudflare in front of Vercel for an extra protection layer (free tier available)

Realistic Cost Estimate for Your Marketing Site

Most likely scenario: $0-20/month

  • Sanity: Free tier (unless you need 20+ editors)
  • Vercel: Free tier for low-moderate traffic, or $20/month Pro for better protection and limits

If traffic grows significantly: $20-50/month

  • Sanity: Still likely free unless you hit API request limits
  • Vercel: Pro plan ($20) + potential small overages

The $2k horror scenario happens when:

  • No rate limiting + bot attack + no spending caps = disaster
  • This is 100% preventable with proper configuration

My Recommendation

Start on free tiers for both, but:

  1. Implement the protective measures I mentioned above from day one
  2. Set up usage monitoring and alerts immediately
  3. Consider starting with Vercel Pro ($20/month) for the DDoS protection and spending limits
  4. Monitor for the first month closely
  5. Document your protection strategy for the agency

The generous free tiers are real, but treat them like production infrastructure - implement proper protections from the start. The horror stories come from developers who didn't set up basic safeguards.

If you don’t do videos my ballpark is that if you have less than 10k visits per month you’re in the free.
vidoes as in like a streaming service or do you mean any product video whatsoever?
Most marketing sites can use Sanity without ever paying us a cent.
However, serving video that’s hosted by Sanity anywhere on your site can be a problem. Sanity is good for very small amounts of that, but since we’re not a video platform we just can’t be competitive with other services like Cloudinary/Mux on that front. Large, unoptimized images can also be a problem, so only calling them at the resolution you need them is highly advised.

You should should be as defensive as possible in terms bots/spam attacks. It doesn’t happen
all of the time, but I do see at least a handful of people per month that are dealing with it. I’d rather spend the time up front preventing it than getting surprise bill. That said, I can’t provide much advice on implementation.
Thanks for all that! I don't think there's going to be much, if any video. I've looked into MUX and that (or a similar service) would be the way to go for streaming large videos. In fact, I had only heard of MUX while browsing Sanity's integrations. So that's fine and that all makes sense. And I'm certainly not trying to see how much I can squeeze ya'll. I just want to be prepared and understand the costs rather than get a huge bill down the road that we didn't plan for.
Yeah, totally understand that! A surprise bill is a nightmare situation.
Company-wise, we want individuals to use the platform for free or very little and
not get a surprise gut punch of a bill. We want folks to have the space to experiment and build because like most SAAS companies, the bulk of our revenue is going to come from Enterprise contracts.
So ... what kind of clients become "Business" or "Enterprise" clients? Like how much traffic/visits per month are they seeing? Do you have any statistics like that you could share?
Oh, that’s such a massive range! I don’t think I could accurately pin it down. Most people move up to Business or Enterprise because they need things like Custom Access Control, longer History, Cloud Cloning, and the like.
Gotcha
One of the reasons this is important to know aside from the obvious is because the agency I'm working with has historically managed the billing themselves and then they turn around and charge the client a flat fee for hosting, but for this project I suggested setting up the billing with the client's payment information, but they'd rather stick with their current billing process.
The client for this project has way more revenue than the agency, so a spike in the bill wouldn't hurt the client as much as it would the agency.
Makes sense. BTW If your agency does end up buying in, become a partner . You can get access to training resources/our agency team to get everyone onboarded
And we don't mind paying flat fees for hosting, but with these pay as you go services, nailing down billing is a little scary.
Oh I bet I could reach out to some of those existing partners and see if any of them would be willing to answer some of our questions.
Actually, yeah! They probably have way more hands on advice than I do

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?