# Control costs: stop, auto-stop, budgets and auto top-up

A GPU server is billed by the second, so the cheapest habit is simple: run it only while you use it. This guide adds the tools that do it for you and the ones that warn you. Every price in the console is live, so this page gives no amounts. Look at the price on the card, on the review step and on the server's **Overview** tab.

## 1. Choose the smallest GPU that fits

1. In **Deploy**, sort by **Price, low to high** and keep **Show available GPUs only** on.
2. Use the **GPU memory** filter. A template that needs more memory than a GPU has cannot be used with it.
3. Select **Price history** on a card to see its price over the last 30 days. It is a record, not a forecast.

The [GPU memory guide](/docs/gpu-memory-guide) shows how much memory a model needs. A small disk also costs less: the line under the disk slider shows the price per hour.

## 2. Know what stopping and deleting cost

| Action | Compute | Disk | Your files |
|---|---|---|---|
| Running | Charged | Charged | Kept |
| **Stop** | Not charged | Charged | Kept |
| **Destroy** | Not charged | Not charged | Deleted |

Stop for a break. Destroy when you are finished and your files are safe elsewhere. A forgotten stopped server keeps paying for its disk. Open **Servers**, set the status filter to **Stopped** and review the list from time to time.

## 3. Use interruptible servers for work that can pause

On the **Review** step of **Deploy**, choose **Interruptible** under **Price**. Both prices are shown side by side.

- The price shown is the most you pay per hour of compute.
- The server can be paused at any time when demand rises. It then shows **Paused**, and processes stop.
- A paused server keeps its disk and costs no compute. It does not resume by itself: select **Start** when you want it back.

Use it for jobs that save checkpoints, not for anything that must stay online. See [Interruptible servers](/docs/interruptible).

## 4. Set a budget and alerts

Owners and admins can do this.

1. Open **Settings** and select the **Budgets** tab.
2. Under **Monthly budget (USD)**, enter an amount, for example `50`.
3. Under **Alert me at**, choose 50%, 80% and 100% of the budget.
4. Optionally set a **Low-balance warning (USD)**.
5. Select **Save**.

Alerts go to the owner by email and appear in the console. The page also shows what you have spent this month. The same from a terminal:

```bash
apidly budget set --monthly 50 --alert 50,80,100
apidly budget
```

You can also turn on **Stop all servers when the monthly budget is reached**. It is off by default. If you turn it on, running servers are stopped as soon as usage reaches the budget, and anything not saved to a disk is lost. New servers cannot start until you raise or remove the budget.

## 5. Let a rule stop the server for you

Open a server, go to **Settings** and find **Automation**. You can also set it on the last step of **Deploy**. Useful rules:

- **Stop after a running time**, for example after 8 hours.
- **Stop when the GPU is idle**, after a number of minutes below a usage you choose.
- **Spending limit**, which stops the server when it has been charged that amount in its life.

The rules accept from 0.25 to 2160 hours of running time, an idle level of 1 to 50 percent for at least 10 minutes, and a spending limit of at least 0.10 USD. A stop by a rule keeps the disk. Each time a rule acts you get an email. See [Automation](/docs/automation).

**Quick start** offers **Stop it automatically** before every start; for your first server it is on and set to 2 hours. To prefill an automatic stop on every new server, open **Settings**, the **Organization** tab, and choose it under **Launch defaults**.

## 6. Watch the balance and get the low-balance email

Open **Billing**, then the **Usage** tab, to see what each server cost. The balance at the top of the console turns to a warning when it is low.

When the balance falls below your **Low-balance warning** (step 4; empty uses the default), we email you the balance, what your running servers use per hour and about how long it lasts. You choose this email under **Settings**, **Notifications**, **Low balance**. If the balance reaches zero, a second email says until when servers keep running; after that grace period, running servers are stopped and paused. Their disks are kept and still billed. See [Billing and balance](/docs/billing-and-balance).

## 7. Turn on auto top-up, with its limits

Auto top-up charges your saved card when the balance gets low, so servers are not stopped when it runs out. Owners and admins can set it.

1. Save a card: it is saved when you add credit, or add one through the payment portal on **Billing**.
2. On **Billing**, under **Auto top-up**, set **When the balance falls to or below** and **Add this amount**. The minimum is shown.
3. Select **Turn on auto top-up**, read the authorisation text, then **Save auto top-up**.

Limits apply whatever you set, so a mistake cannot drain your card:

- at most one automatic charge an hour;
- at most 4 automatic charges in 24 hours;
- at most 5,000 USD in 24 hours and 20,000 USD in 30 days, both counted on a rolling basis.

When a limit is reached, no automatic charge is made until there is room again; you can still add credit by hand. After two failed automatic payments in a row, or when your bank asks you to confirm a payment, auto top-up turns itself off and we email you. See [Auto top-up](/docs/auto-top-up).

Auto top-up keeps servers running, so pair it with a monthly budget (step 4) and automatic stops (step 5).

## When you are done: stop or delete

Before you close the laptop, open **Servers** and check that nothing is running that you do not need. Stop what you will use again, and destroy the rest.

## Next

- [Automate with the CLI and API](/docs/tutorial-cli-and-api)
- [Pricing explained](/docs/pricing-explained)
- [Check the price before you launch](/docs/tutorial-check-the-price)
- [Keep an eye on spending from scripts](/docs/tutorial-spending-from-scripts)
