Managed AI Infra vs. Self-Hosted: Pick One
For: A Series A SaaS CTO whose AI feature just crossed 50K daily active users and whose managed inference bill tripled last quarter — now evaluating whether to move model serving in-house before the next funding milestone
Your managed inference bill tripled last quarter, you crossed 50K DAU on the AI feature, and someone on your team built a spreadsheet showing self-hosted Llama on rented H100s would cost a third as much. The spreadsheet is probably right about compute. It is almost certainly wrong about the decision.
The managed-vs-self-hosted choice gets framed as a cost comparison. It isn't. It's a staffing decision wearing a compute-pricing costume. The GPU bill is the part you can model in a spreadsheet. The senior ML-ops attention you'll permanently divert from product work — that's the line item nobody quotes you, and it's the one that decides whether this move is right.
Here is the framework I'd use if I were sitting in your chair.
Define the decision crisply
You are not choosing a vendor. You are choosing where, on a spectrum, you want to sit:
- Fully managed inference (OpenAI, Anthropic, Bedrock, Vertex). You send tokens, you get tokens. Zero infra surface area.
- Managed model hosting (Together, Fireworks, Replicate, Modal, Anyscale, SageMaker endpoints). You pick the model and rough hardware shape; they run the cluster.
- Self-hosted on rented GPUs (Lambda, CoreWeave, RunPod, or hyperscaler GPU instances). You own vLLM/TGI, autoscaling, observability, model rollouts, failover.
- Self-hosted on owned hardware. Almost no Series A SaaS should be here. Ignore it for this post.
Most CTOs in your position think they're choosing between #1 and #3. The interesting answer is usually #2 — and the framework below tells you when it isn't.
The five axes that actually matter
1. ML-ops surface area budget
How many senior engineer-weeks per quarter can you permanently lose to cluster health without slowing the product roadmap? Be honest. Not "weeks we could spare" — weeks you will lose, every quarter, forever, once you self-host.
The work doesn't go away after launch. It compounds. GPU node dies at 2am. vLLM version bumps that change tokenizer behavior in ways your evals don't catch. A new model release that your serving stack needs a week to support. Autoscaling that thrashes during traffic spikes. CUDA driver mismatches after an AMI update.
If your answer is "we have one strong infra engineer who's curious about GPUs" — that is not a self-hosting budget. That is a 3-month enthusiasm window followed by an on-call burden that will cause that engineer to quit.
2. The latency percentile your UX contract actually requires
Not p50. Look at p95 and p99 of your current managed provider. Then ask: does our product break at p99 = 4 seconds, or is that fine?
This axis flips intuition. People assume self-hosting wins on latency because you control the stack. Sometimes true. But managed providers have already solved cold starts, speculative decoding, prefix caching, and continuous batching at a scale you won't match for a while. If your UX tolerates 2–5 second p99 (most chat features do), managed providers are competitive or better. If your UX requires sub-500ms p99 with predictable tails (voice, autocomplete, agentic loops with many sequential calls), the calculus changes — but the answer is usually a specialized managed provider (Groq, Fireworks, Together with dedicated capacity), not self-hosting.
3. Data residency and compliance posture
This axis sometimes makes the decision for you, and people miss it because their compliance team hasn't escalated yet. Ask:
- Do any of your customers' contracts require data stay in a specific region?
- Are you selling into healthcare (HIPAA), EU (GDPR Article 44 transfers), financial services, or government?
- Does your DPA forbid sub-processors from training on your data, even with opt-outs?
If yes to any, your decision space shrinks fast. Bedrock and Vertex in-region cover a lot of this. Pure OpenAI does not, even with the enterprise commitments. Self-hosted on rented GPUs in a region you control covers it, but only if your provider gives you proper VPC isolation and a BAA where relevant.
We saw this play out concretely on HealthPotli, where drug-interaction inference had to sit inside boundaries that ruled out a chunk of the managed options before we got to cost.
4. Workload shape and predictability
Managed per-token pricing is fantastic for spiky, unpredictable, varied workloads. It's a tax on flat, predictable, high-volume ones.
Look at your traffic for the last 60 days and answer:
- What's the ratio of peak to trough QPS? (If <3x, your workload is flat — self-hosting amortizes well.)
- What fraction of calls hit the same 1–2 models with similar prompt shapes? (High concentration = self-host candidate. Long tail of model/prompt variety = stay managed.)
- How much of your prompt is shared prefix across requests? (Prefix caching on a self-hosted vLLM cluster can cut effective cost dramatically — but only if you control the serving layer.)
The 3x bill jump you're seeing is often not "managed is expensive." It's "our workload became predictable and high-volume, and per-token pricing stopped being the right unit." That's a signal for managed-model-hosting with dedicated capacity, which is the middle path most teams skip past.
5. Model strategy: frontier vs. open-weight
If your product quality depends on GPT-4-class or Claude-Opus-class frontier models, self-hosting is not on the table — those models aren't available to host. The decision is between managed frontier and managed open-weight.
If you've already validated that a fine-tuned Llama 3.1 70B or Qwen 2.5 or Mistral variant meets your quality bar, self-hosting becomes possible. But verify this with offline evals on your actual production traffic, not on MMLU. The gap between "works on benchmarks" and "works on your users' weird inputs" is the gap that kills self-hosting projects six months in.
Honest scoring of the three options
Fully managed inference (OpenAI / Anthropic / Bedrock)
Good at: Zero infra burden. Best models. Fast iteration. Compliance available if you pick the right tier. Excellent for spiky or varied workloads.
Bad at: Unit economics break down at scale. Per-token pricing punishes long prompts and high-volume predictable calls. Limited control over latency tails. Vendor lock-in on prompts, fine-tunes, and behavior. Rate limits that bite during growth spikes.
Choose when: You're pre-product-market-fit on the AI feature, you need frontier model quality, your workload is varied, or your team has zero ML-ops bandwidth.
Managed model hosting (Together / Fireworks / Bedrock custom / SageMaker)
Good at: Captures most self-hosting cost savings without the operational burden. Dedicated endpoints give predictable latency. Open-weight models with their fine-tunes. You skip the cluster operations entirely. Often the right answer and rarely the first one considered.
Bad at: Still a vendor. Still abstraction tax — usually 30–50% premium over raw GPU costs depending on provider and commit. Less knob-turning than self-hosted (no custom kernels, no exotic quantization schemes). Can have noisy-neighbor issues on shared tiers.
Choose when: Your workload is concentrated on 1–3 open-weight models, you want predictable cost, and you don't want to staff an ML-ops function.
Self-hosted on rented GPUs
Good at: Best raw unit economics at sustained high volume. Full control of the stack — vLLM tuning, prefix caching, custom quantization, speculative decoding. No per-token markup. Data never leaves your VPC.
Bad at: Permanent senior ML-ops cost — not one hire, a function. Capacity planning is your problem. GPU shortages are your problem. Model rollouts, canary testing, rollback are your problem. The first 6 weeks feel great; month 8 is when the on-call rotation starts costing you a senior engineer's sanity. Slower to adopt new open-weight models because someone has to validate the serving stack supports them.
Choose when: You have sustained predictable volume, your workload is concentrated on 1–2 models, you have or can hire genuine ML-ops talent (not a generalist backend engineer who'll figure it out), and the savings are large enough to justify carrying that function indefinitely.
The decision rules
Walk through these in order. The first one that applies is your answer.
If your data residency or compliance obligations rule out your current provider
The decision is already made for you. Move to Bedrock/Vertex in-region, or self-host in a region you control. Cost is not the deciding factor here; contracts are. Don't relitigate it.
If your AI feature is still pre-PMF or you're iterating model choice monthly
Stay fully managed. The cost of slow iteration is bigger than the cost of per-token pricing. Revisit in two quarters when the feature stabilizes.
If your workload is concentrated, predictable, and on open-weight models — but you don't have ML-ops staff
Move to managed model hosting with dedicated capacity (Fireworks, Together, Bedrock custom endpoints). This is the answer for most Series A teams in your situation. You capture 60–80% of the self-hosting savings, you get predictable monthly costs, you keep zero ML-ops burden. This is the option people skip because it doesn't appear in the "managed vs self-hosted" framing.
If you have sustained high volume, a concentrated workload, AND a credible ML-ops hire or existing team
Self-host on rented GPUs. But scope it honestly: you're committing to staff a function, not run a project. Plan for a senior ML-ops engineer plus on-call support from one other engineer. If you can't budget that headcount permanently, you can't afford to self-host — go to managed model hosting instead.
If your AI feature is core to your product moat and your customers' switching cost
Bias toward more control, not less. That doesn't necessarily mean full self-hosting, but it means avoiding deep lock-in on prompts and behaviors specific to one closed model. Build your eval infrastructure so you can swap models — and let that capability decide your serving layer.
What people get wrong
Three patterns I see repeatedly in teams making this call:
Underestimating the "managed model hosting" middle. The debate gets framed as OpenAI vs. owning a Kubernetes cluster with GPU nodes. The middle path captures most of the upside with a fraction of the burden, and it's where most teams should land.
Modeling cost on current volume instead of next year's volume. If you self-host today's load, you've optimized for a snapshot. Workload shape changes as you add features. Build a model that survives 5x growth and a model release that changes your preferred architecture mid-year.
Treating ML-ops as a project, not a function. "We'll migrate to self-hosted in Q3" is a project framing. "We'll run a model-serving function with named owners and on-call rotation indefinitely" is a function framing. The second is the truth. If you can't commit to the second, don't start the first.
A practical sequence
If you're at 50K DAU with a bill that tripled, here's the order I'd run:
- Run a 2-week eval comparing your current managed model against the best open-weight candidate on your actual production traffic. If quality drops below your bar, stop — stay managed and renegotiate volume pricing.
- Profile your workload: peak/trough ratio, model concentration, prompt shape. This tells you whether managed model hosting will win.
- Get dedicated-capacity quotes from two managed model hosts. Compare against your current managed bill and a realistic self-hosting estimate (GPU rental + ~1.5 FTE permanent ML-ops loading).
- If the gap between managed model hosting and self-hosting is less than the fully-loaded cost of an ML-ops function, stop there. Take the managed hosting win.
- If the gap is meaningfully larger, and you can actually hire the role, plan the self-hosted migration — starting with non-critical traffic and a real rollback path.
We've walked teams in fintech (GimBooks) and lending (Cashpo) through versions of this when their inference patterns shifted from exploratory to production-shaped. The answer rarely matched what the cost spreadsheet predicted on day one.
Frequently Asked Questions
When does self-hosting an LLM actually start making sense for a SaaS startup?
When three conditions hold simultaneously: your workload is concentrated on 1–2 open-weight models, your volume is predictable enough that dedicated capacity beats per-token pricing, and you can permanently staff an ML-ops function (not just hire one curious engineer). Miss any of the three and managed model hosting is almost always the better answer.
Is self-hosting cheaper than managed inference?
On raw GPU economics, often yes — sometimes 3–5x at sustained volume. On fully-loaded cost including senior ML-ops headcount, on-call burden, capacity planning, and slower model adoption, the gap usually narrows or inverts for teams under ~$1M/year in managed spend. The unit price comparison is the wrong number to optimize.
What's the difference between managed model hosting and fully managed inference?
Fully managed inference (OpenAI, Anthropic) gives you a model behind an API — you don't pick the hardware or even know it exists. Managed model hosting (Fireworks, Together, Bedrock custom endpoints) lets you pick an open-weight model and rough capacity shape, and the provider runs the cluster. The second captures most self-hosting economics without the operational burden.
How do data residency requirements affect this decision?
They often make it for you. HIPAA, GDPR in-region requirements, and financial-services DPAs can rule out major managed providers entirely, or restrict you to specific regions and tiers (Bedrock, Vertex). Check your customer contracts and DPAs before running any cost comparison — the residency constraint sets the option space, and cost only matters within what's left.
How should I estimate the timeline and investment for migrating to self-hosted inference?
It depends heavily on your current architecture, traffic patterns, compliance scope, and team composition — there isn't a generic answer worth quoting. For a grounded assessment based on your specific workload and team, talk to CodeNicely for a personalized review.
The shortest version of this post: don't decide between managed and self-hosted. Decide whether you're willing to staff a permanent ML-ops function. If yes, self-host can pay off. If no, managed model hosting is the answer you were looking for — and the one the "managed vs self-hosted" framing hid from you.
Found this useful? CodeNicely publishes engineering and product playbooks weekly. Browse the archive or tell us what you're building.
_1751731246795-BygAaJJK.png)