Plan your build
AI Stack Cost Calculator
Estimate your AI app stack cost at scale — hosting, database, auth, AI APIs, and services in one view.
Result
AI API is 99.06% of your costs at 1K users. Consider caching responses, using a cheaper model for common queries, or batching requests.
Cost breakdown by category
Per-tier monthly cost split across stack categories.
Vendor list prices as of 2026-10-11 (AI models verified2026-10-09); verify against vendor pricing pages for current rates.
Figures from Anthropic, OpenAI, Google Gemini, Vercel, Supabase, Clerk, Resend, PlanetScale, Neon, Fly.io, Render, Railway, Auth0, Kinde and Postmark, checked on October 11, 2026.
How to use it
- Choose your hosting provider and plan tier (Vercel, Railway, DigitalOcean, Fly.io, Render, or a custom figure). Hosting is usually a flat monthly plan, so it matters most at small scale and least once AI calls grow.
- Select your database and authentication provider. Watch where each free or included tier ends: on the presets, Clerk is free up to 50,000 monthly retained users, Auth0 up to 25,000, Supabase Auth up to 100,000, and PlanetScale has no free plan (from $5 a month). Self-hosted Auth.js has no per-user fee.
- Configure the AI usage: the model you call most, the average input and output tokens per request, and calls per active user per day. These three numbers drive most of the variable cost. One call with 1,000 input and 500 output tokens costs $0.007 on Claude Sonnet 5.5 and $0.003 on GPT-5.4 mini, so 10 calls a day for 10,000 users is about $21,000 against $9,000 a month.
- Add email, monitoring, your domain and any other recurring charges. The presets list Resend from free to $20 a month, Postmark from $15 and Sentry Team at $26; these rarely decide the budget, but leaving them out understates it.
- Read the monthly cost at your user count, then the scale table at 100, 1,000, 10,000 and 100,000 users. The calculator names the line that dominates; if it is the AI API, change the model, the tokens per call or the calls per user and watch the total, before you spend time on hosting.
Questions people usually ask
What cost categories does this calculator cover?
Eight recurring lines: hosting (Vercel, Railway, DigitalOcean, Fly.io, Render), database (Supabase, PlanetScale, Neon, Turso), authentication (Clerk, Supabase Auth, Auth0, Kinde, or self-hosted Auth.js/NextAuth), AI API calls (OpenAI, Anthropic and Google models, or open source), email (Resend, Postmark, SendGrid), monitoring (Sentry, LogRocket), your domain, and a line for anything else. Each preset carries the provider's published list price, last checked on October 11, 2026. Payment processing is not a stack cost the calculator models: Stripe's standard US card rate is 2.9% + 30 cents per charge, so put it in the other line or, better, in your margin calculation.
Why is AI API cost usually the dominant expense?
Because it is the only line that grows with every request. A call to Claude Sonnet 5.5 ($2 per million input tokens, $10 per million output) with 1,000 input and 500 output tokens costs $0.007. At 10 calls per user per day for 10,000 users, that is 3 million calls and about $21,000 a month, while the hosting presets in this calculator list at $0 to $25 a month before usage. The same traffic on GPT-5.4 mini ($0.75 and $4.50 per million) costs about $9,000 a month, which is why the model choice is the first number to get right.
How should I optimize AI costs as I scale?
In order of how directly they cut the bill: route simple requests to a cheaper model (Gemini 3.5 Flash-Lite lists at $0.30 per million input tokens against Claude Sonnet 5.5's $2), cache responses you can reuse, trim the tokens you send on every call (system prompt, examples, retrieved context), and use your provider's batch and prompt-caching discounts where a request can wait or repeats a long prefix. Each of these changes an input the calculator already has, so you can see what a given cut is worth before you build it.
What gross margin should an AI-powered product target?
Enough to cover everything that is not in this calculator: support, marketing, your own pay and the next hire. There is no published benchmark for AI products we would stand behind, so work it out from your own operating costs: if those take half of revenue, a 50% gross margin leaves nothing. The AI Product Margin Calculator puts this stack cost against your price per user, and the Model Price Drop Stress Test shows how much of the margin depends on the model's price.
How do costs scale differently between fixed and variable components?
Hosting plans, monitoring subscriptions and the domain stay flat. AI calls grow with every user, and auth, database and email grow in steps once you pass a provider's free or included tier. The scale table prices your stack at 100, 1,000, 10,000 and 100,000 users, so you can see where per-user cost falls as fixed costs spread out and where a free tier ends. Auth is the clearest step: on the presets, Clerk costs nothing up to 50,000 monthly retained users and $1,025 a month at 100,000, Auth0 is free to 25,000 and $7,000 at 100,000 because its paid plan prices every user, and Supabase Auth stays free to 100,000.
Are the prices in this calculator accurate and current?
They are the providers' published list prices as of October 11, 2026. Providers change plans often, and negotiated, usage-based or regional pricing can differ from list, so confirm the current price on the provider's page before you commit a budget.
How does this compare to building versus using managed services?
The presets price managed services. Self-hosting removes some lines (self-hosted Auth.js has no per-user fee) but adds servers, upgrades and on-call time that are not in this calculator. The Build vs Buy Decision Engine puts that time against the subscription for each component.
Is this tool free and private to use?
Yes. AI Biz Hub tools are free, no-signup browser tools. All calculations run locally in your browser. No input data is sent to any server, stored, or shared.
Is this professional business or financial advice?
No. Outputs are planning estimates based on published provider pricing. Actual costs depend on usage patterns, negotiated rates, architectural choices, and provider-specific billing details not fully captured in any calculator. Use the outputs for budgeting and comparison, then verify with provider pricing pages before making financial commitments.
The same numbers as a table
- Reference 2026 AI vendor pricing and TCO report
Precomputed by this calculator across common inputs, to cite or download as CSV.
Related calculators
- Plan the build Vibe Code Platform Comparison
Compare Cursor, Bolt, Lovable, Replit, and v0 for your project type, complexity, and skill level.
- Plan the build Embeddings DB Cost
Pinecone, Postgres+pgvector, LanceDB, or Turbopuffer — cheapest for your workload.
- Pricing Micro-SaaS Pricing Engine
Find your price floor, suggested price, and ceiling from per-user costs, competitor benchmarks, and target margin.
- Startup Bootstrapped Runway Calculator
Calculate personal runway and months to ramen/fully profitable from savings, side income, and MRR growth.
Background on the AI Stack Cost Calculator
- Alternatives Cursor Alternatives for Developers (2026)
Cursor alternatives in 2026: Windsurf (now Devin Desktop), GitHub Copilot, Claude Code and Zed compared on price, billing model and fit for solo devs.
- Alternatives Pinecone Alternatives for Vector Search (2026)
Pinecone alternatives in 2026: Qdrant, Weaviate, and pgvector compared on price and fit. Pinecone starts at $20/mo Builder; pgvector reuses your Postgres.
Articles
- 14 min read The 2026 AI Solopreneur Stack
Vendor and architecture stack for solo AI founders in 2026: model, vector store, edge compute, payments, auth and monitoring, costed at three scales.
- 10 min read Embeddings DB vs Self-Host pgvector: True Cost
Embeddings DB vs pgvector true cost: Supabase pgvector is $125-$426/mo at 200k-1M vectors vs Turbopuffer $16; it wins if Postgres is already in use.
- 9 min read Vendor Lock-In Math: The Real Cost of Switching LLMs
Vendor lock-in math for LLMs: switching providers costs engineering hours, not API code. Price evals, prompts and parallel running, then the payback.
More in AI product economics
Understand the costs, margins, and pricing of building AI-powered products.
- Startup Cost Estimator
- Profit Margin Calculator
- Profit Margin / Markup / Discount Calculator
- SaaS Pricing Strategy Calculator
Use it from code
The same calculation as a JavaScript module you can import. It runs where you import it, with no request, key or rate limit.
import { compute } from "https://aibizhub.io/engines/ai-stack-cost-calculator.js"; Input and output contract, TypeScript types and the guide for agents.