# Mass Percent Calculator

> Computes the mass percent (% w/w) of a solute from the solute mass and either the total solution mass or the solvent mass, and expresses the same concentration as mass fraction, parts per million and parts per billion.

- Calculator id: `mass-percent` · Category: Chemistry (`chemistry`) · Tool name: `calculate_mass_percent`
- Canonical page: https://tttkmbb.com/chemistry/mass-percent · This document: https://tttkmbb.com/chemistry/mass-percent.md · JSON definition: https://tttkmbb.com/chemistry/mass-percent.json

## Purpose

Computes the mass percent (% w/w) of a solute from the solute mass and either the total solution mass or the solvent mass, and expresses the same concentration as mass fraction, parts per million and parts per billion.

**Use when:** You need the % w/w, ppm or ppb concentration of a solute in a solution or mixture from masses.

**Do not use when:** You need molarity (mol/L, use molarity), the percent composition of an element within a compound (use molar-mass), or volume-based units such as % v/v.

## Input

| Parameter | Type | Unit | Required | Description |
| --- | --- | --- | --- | --- |
| `solute_mass` | number |  | required | Mass of the solute in any unit shared by all masses (g, kg, mg). (> 0) |
| `solvent_mass` | number |  | optional | Mass of the solvent; solution mass = solute + solvent. Ignored when solution_mass is given. (min 0) |
| `solution_mass` | number |  | optional | Total mass of the solution (solute + solvent). Use this when the total, not the solvent, is known. (> 0) |

## Output

| Field | Type | Unit | Description |
| --- | --- | --- | --- |
| `mass_percent` | number | % w/w | 100 × solute_mass / solution_mass. |
| `mass_fraction` | number |  | solute_mass / solution_mass. |
| `ppm` | number | ppm | 10⁶ × mass fraction (mg per kg of solution). |
| `ppb` | number | ppb | 10⁹ × mass fraction (µg per kg of solution). |
| `solution_mass` | number |  | Total mass of the solution, in the input unit. |
| `solvent_mass` | number |  | solution_mass − solute_mass, in the input unit. |

## Formula

`mass_percent = 100 × solute_mass / solution_mass, where solution_mass = solute_mass + solvent_mass; ppm = 10⁶ × solute_mass / solution_mass; ppb = 10⁹ × solute_mass / solution_mass`

## Data Sources

- OpenStax Chemistry 2e – 3.4 Other Units for Solution Concentrations — https://openstax.org/books/chemistry-2e/pages/3-4-other-units-for-solution-concentrations (textbook, retrieved 2026-09-23)
- Wikipedia – Mass fraction (chemistry) — https://en.wikipedia.org/wiki/Mass_fraction_(chemistry) (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/mass-percent?solute_mass=…`
- `POST https://tttkmbb.com/api/v1/calculate/mass-percent` 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/mass-percent · OpenAPI operationId `calculate_mass_percent` 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": "mass-percent", "inputs": {…}}`

## Example

- 5 g NaCl in 95 g water: inputs `{"solute_mass":5,"solvent_mass":95}` → `{"mass_percent":5,"mass_fraction":0.05,"ppm":50000,"ppb":50000000,"solution_mass":100,"solvent_mass":95}`
- 2 mg of lead in 1 kg of solution: inputs `{"solute_mass":0.002,"solution_mass":1000}` → `{"mass_percent":0.0002,"ppm":2,"ppb":2000,"solvent_mass":999.998}`

```
GET https://tttkmbb.com/api/v1/calculate/mass-percent?solute_mass=5&solvent_mass=95
```

## Limitations

You need molarity (mol/L, use molarity), the percent composition of an element within a compound (use molar-mass), or volume-based units such as % v/v. All values are computed from the formula above; no measurement or live data is involved.

## FAQ

**Is the denominator the solvent or the whole solution?**

The whole solution (solute + solvent). 5 g of salt in 95 g of water is 5% w/w, not 5.26%.

**Is 1 ppm the same as 1 mg/L?**

Only for dilute aqueous solutions whose density is about 1 kg/L; ppm here is strictly mass-based (mg of solute per kg of solution).

## Related

- [Molarity Calculator](https://tttkmbb.com/chemistry/molarity.md) — Molar concentration instead of mass-based concentration.
- [Dilution Calculator](https://tttkmbb.com/chemistry/dilution.md) — Dilute the solution to a lower concentration.
- [Percentage Calculator](https://tttkmbb.com/math/percentage.md) — General percentage arithmetic.
