# Fuel Cost Calculator

> Estimates the fuel needed for a trip and its cost from distance, fuel consumption in litres per 100 km and the price per litre, with the cost per person when it is shared.

- Calculator id: `fuel-cost` · Category: Everyday Life (`everyday`) · Tool name: `calculate_fuel_cost`
- Canonical page: https://tttkmbb.com/everyday/fuel-cost · This document: https://tttkmbb.com/everyday/fuel-cost.md · JSON definition: https://tttkmbb.com/everyday/fuel-cost.json

## Purpose

Estimates the fuel needed for a trip and its cost from distance, fuel consumption in litres per 100 km and the price per litre, with the cost per person when it is shared.

**Use when:** You want to budget a road trip or commute, or split fuel money between passengers, and know the car's consumption in L/100 km.

**Do not use when:** Your consumption is in mpg or km/L (convert it first with fuel-economy), or you need total ownership costs such as tolls, wear or depreciation.

## Input

| Parameter | Type | Unit | Required | Description |
| --- | --- | --- | --- | --- |
| `distance_km` | number | km | required | Trip distance in kilometres (enter the round-trip distance for a return journey). (> 0, max 100000) |
| `fuel_consumption_l_per_100km` | number | L/100 km | required | Average consumption in litres per 100 km. (> 0, max 100) |
| `fuel_price_per_liter` | number | per L | required | Price per litre in your currency. (min 0, max 100) |
| `passengers` | integer |  | optional, default 1 | Number of people sharing the fuel cost, driver included. (min 1, max 100) |

## Output

| Field | Type | Unit | Description |
| --- | --- | --- | --- |
| `fuel_liters` | number | L | distance × consumption / 100. |
| `total_cost` | number |  | fuel_liters × price per litre. |
| `cost_per_person` | number |  | total_cost / passengers. |
| `cost_per_km` | number | per km | total_cost / distance_km. |
| `equivalent_mpg_us` | number | mpg (US) | 235.215 / (L/100 km), for reference. |

## Formula

`fuel_liters = distance_km × fuel_consumption_l_per_100km / 100; total_cost = fuel_liters × fuel_price_per_liter; cost_per_person = total_cost / passengers; cost_per_km = total_cost / distance_km; mpg_us = 235.215 / L_per_100km`

## Data Sources

- US DOE / EPA – fueleconomy.gov Trip Calculator — https://www.fueleconomy.gov/trip/ (government, retrieved 2026-09-23)
- Fuel economy in automobiles – unit conversions (Wikipedia) — https://en.wikipedia.org/wiki/Fuel_economy_in_automobiles (reference, retrieved 2026-09-23)

Data freshness: `static`. Deterministic formula with fixed constants; results never go stale. Inputs supplied by the caller determine the output.

## API

- `GET https://tttkmbb.com/api/v1/calculate/fuel-cost?distance_km=…&fuel_consumption_l_per_100km=…&fuel_price_per_liter=…`
- `POST https://tttkmbb.com/api/v1/calculate/fuel-cost` with JSON body `{"inputs": {…}}`
- Response: unified envelope (`success`, `request`, `result.values`, `result.units`, `sources`, `freshness`, `timestamp`, `next_actions`, `links`); see https://tttkmbb.com/docs/response-format.md
- Schema: https://tttkmbb.com/api/v1/calculators/fuel-cost · OpenAPI operationId `calculate_fuel_cost` in https://tttkmbb.com/openapi.json
- Authentication: none. Rate limit: fair use, see https://tttkmbb.com/docs/rate-limits.md.

## MCP

- Server: `https://tttkmbb.com/mcp` (Streamable HTTP, JSON-RPC 2.0, no auth)
- Tool:  `run_calculator` with `{"calculator_id": "fuel-cost", "inputs": {…}}`

## Example

- 350 km at 7.5 L/100 km, 1.85 per litre, 2 people: inputs `{"distance_km":350,"fuel_consumption_l_per_100km":7.5,"fuel_price_per_liter":1.85,"passengers":2}` → `{"fuel_liters":26.25,"total_cost":48.56,"cost_per_person":24.28,"cost_per_km":0.139,"equivalent_mpg_us":31.4}`
- 1200 km at 6.2 L/100 km, 1.60 per litre: inputs `{"distance_km":1200,"fuel_consumption_l_per_100km":6.2,"fuel_price_per_liter":1.6}` → `{"fuel_liters":74.4,"total_cost":119.04,"cost_per_person":119.04,"cost_per_km":0.0992,"equivalent_mpg_us":37.9}`

```
GET https://tttkmbb.com/api/v1/calculate/fuel-cost?distance_km=350&fuel_consumption_l_per_100km=7.5&fuel_price_per_liter=1.85&passengers=2
```

## Limitations

Your consumption is in mpg or km/L (convert it first with fuel-economy), or you need total ownership costs such as tolls, wear or depreciation. All values are computed from the formula above; no measurement or live data is involved.

## FAQ

**I know my car's mpg, not L/100 km. What do I enter?**

L/100 km = 235.215 / mpg (US gallons) or 282.481 / mpg (UK imperial gallons). 30 US mpg is about 7.84 L/100 km.

**Does real consumption match the manufacturer figure?**

Usually not; highway driving, load, speed and air conditioning change consumption by 10–30%. Use a measured average from recent fill-ups if you have one.

## Related

- [Fuel Economy Converter](https://tttkmbb.com/conversion/fuel-economy.md) — Convert mpg or km/L to L/100 km first.
- [Bill Split Calculator](https://tttkmbb.com/everyday/bill-split.md) — Split any shared cost, with an optional tip.
