# Local or cloud: which should I use?

> Local wins on privacy, marginal cost and availability. Cloud wins on the largest models and zero setup, so most people end up using both.

Use both. Local is better for private work, high volume and anything that must keep running offline. Cloud is better for the hardest problems and for anything you need today without buying hardware.

## Where local wins

### Privacy

Your prompts never leave the machine. There is no provider log, no retention policy to read and no question of whether your data trains the next model. For client files, medical notes, source code under contract or anything personal, that settles it. [Is local AI actually private?](https://localagi.co/privacy-and-security) covers what local does and does not protect.

### Marginal cost

Once you own the hardware, each extra token costs only electricity. That changes how you use a model. You can run a summary over ten thousand documents, leave an agent working overnight or retry a prompt fifty times without watching a meter.

### Latency on small tasks

A local model has no network round trip and no queue. For short jobs such as autocomplete, a quick rewrite or a classification step, the answer can start before a cloud request would have reached the server. [Can a local model autocomplete my code?](https://localagi.co/coding-autocomplete) depends on this.

### Availability

A local model works on a plane, during an outage and after a provider retires the version you built on. The file you downloaded will behave the same way in five years. Nobody can change it, rate-limit it or raise its price.

## Where cloud wins

### The largest models

The best closed models are still ahead of anything you can run at home, especially on hard coding, long research and rare knowledge. The largest open models are close, but they need about 250 GB to 1.6 TB of memory at 4-bit. Almost nobody has that on a desk.

### Zero setup

A cloud model is a sign-up and an API key. There is no download, no [Will the model fit in my memory?](https://localagi.co/memory) maths, no [template](https://localagi.co/chat-templates) trouble and no driver to update. For a one-off task, that is hard to beat.

### Burst capacity

A cloud provider can run a hundred requests at once for an hour and then nothing. A local machine runs as fast as it runs. If your load is spiky, renting beats owning.

**The catch.** 
Cloud prices, limits and model versions change without asking you. A workflow that is cheap and reliable this month can be neither next month. Keep the prompts and code portable so you can move.

## The hybrid setup

Most people who stick with local AI end up with a split. A local model handles the everyday and the private. A cloud model handles the hardest tenth of the work.

- **Your apps**: Chat, coding tools, scripts
- **One API format**: OpenAI-compatible endpoint
- **Local model**: Private work, bulk jobs, autocomplete
- **Cloud model**: Hard problems, the largest models

Local runtimes such as [Ollama](https://localagi.co/ollama), [LM Studio](https://localagi.co/lm-studio) and [llama.cpp](https://localagi.co/llama-cpp) serve the same OpenAI-compatible API that many cloud providers use. Point an app at a local address for one job and a cloud address for the next. [How do I call a local model from code?](https://localagi.co/local-api) shows how.

**Rule of thumb.** 
Send it to the cloud only when the local model has failed at it, or when the data is not private and you need the best answer now.

## A cost sketch

Local hardware is a fixed cost spread over its life. Cloud is a cost per token. Comparing them is a short sum, and the answer depends almost entirely on how many tokens you use.

1. Count your tokens. Estimate how many tokens you send and receive per month. Your cloud provider's usage page shows this, or you can count requests times average length.
2. Price the cloud side. Multiply input and output tokens by the provider's current rates. Output usually costs several times more than input.
3. Price the local side. Take the hardware cost and divide by the months you expect to use it, often 36. Add electricity: watts under load, times hours of use, times your power rate.
4. Check the quality match. Only compare against a cloud model your local model can actually stand in for. Replacing a frontier model with a small local one is not a saving if the work gets worse.

The pattern is consistent. Light, occasional use is cheaper in the cloud. Heavy, steady use, such as agents, batch jobs or a whole team, is where local hardware pays for itself. [What does a million tokens cost me?](https://localagi.co/cost-calculator) runs these numbers with current prices, and [When is local cheaper than an API?](https://localagi.co/economics) works through the break-even in detail for teams and servers.

**Try it.** 
Open the usage page of any cloud AI account you have and note last month's token count. Put it into [What does a million tokens cost me?](https://localagi.co/cost-calculator) with the hardware you are considering.

## Go deeper

### What the sketch leaves out

Your time is the biggest hidden cost. Setting up and maintaining a local stack takes hours, and those hours are free only if you enjoy them. A cloud API also includes things you would otherwise build, such as uptime, scaling and monitoring.

On the other side, hardware keeps resale value, and one machine can serve several people or jobs at once. A Mac bought for local AI is also still a Mac.

### Electricity

A laptop running a model draws tens of watts. A desktop with a large graphics card can draw several hundred under load. At typical household rates, power is a small part of the total for one person and a real line item for a server that runs all day. [What does it cost to run?](https://localagi.co/power-and-cost) has the figures.

### Privacy in the hybrid setup

A hybrid setup is only as private as its routing. If an app sends some requests to the cloud, check which ones before you paste anything sensitive. The safest pattern is a separate app or profile that can only reach the local model.
