CONVERT Function

Converts a measurement from one unit to another.

Category

Engineering

Available in

All versions, Microsoft 365

Returns

A number

Want to practice CONVERT in a real spreadsheet? Open a blank sheet in our Practice Sandbox and try it with live data, with the AI Excel tutor beside you. No Excel needed — just a free account.Try it free in the Sandbox

Overview

CONVERT changes a value between units of the same kind — weight, distance, time, pressure, energy, power, temperature, volume, area, speed, information and more. Units are typed as short codes such as "kg", "mi" or "C".

Metric prefixes work too: "k" for kilo, "m" for milli, "c" for centi — so "km", "mm" and "cm" all work from "m". Binary prefixes such as "Gi" (gibi) apply to "byte" and "bit".

Syntax

=CONVERT(number, from_unit, to_unit) Explain

Arguments

ArgumentRequired?What it does
numberYesThe value to convert.
from_unitYesThe unit the number is in, as a code in quotes (case-sensitive).
to_unitYesThe unit you want. Must measure the same thing as from_unit.

Examples

Example 1 — Shipping and logistics conversions

Northstar's suppliers quote in different units. Column B and C hold the unit codes. Results are rounded to 4 decimal places here.

D2fx=CONVERT(A2,B2,C2)
ABCD
1ValueFromToResult
225kglbm55.1156
3100kmmi62.1371
430CF86
550lgal13.2086
612incm30.48
=CONVERT(A2,B2,C2) Explain

Example 2 — Common unit codes

A quick reference. Codes are case-sensitive: "Pa" is pascal, "pa" isn't.

AB
1KindCodes
2Weightg, kg, lbm (pound), ozm (ounce), stone, ton
3Distancem, km, cm, mm, in, ft, yd, mi, Nmi
4Timesec (or s), mn (minute), hr, day, yr
5TemperatureC, F, K
6Volumel, ml, gal, uk_gal, qt, pt, cup, tsp, tbs
7Aream2, ft2, ha, uk_acre (or us_acre)
8Speedm/s, km/h, mph, kn
9Energy & powerJ, cal, kWh, BTU · W, kW, HP
10Informationbit, byte, kbyte, Mibyte, Gibyte

Example 3 — Hours to minutes

Time units convert too.

=CONVERT(2.5,"hr","mn") Explain

Returns 150.

Common mistakes

  • #N/A A unit code is misspelled, uses the wrong case ("KG"), or the two units measure different things ("m" to "kg").
  • Minutes are "mn", not "min". In CONVERT, "min" doesn't mean minutes. Use "mn" for minutes and "sec" for seconds.

Notes

  • Temperature conversions handle the offsets for you: CONVERT(100,"C","F") is 212, not 180.
  • Related functions: ROUND, TEXT.
Kyle Stott

Author

Kyle Stott

Certified Microsoft Excel Expert

Kyle has worked professionally with Microsoft Excel for over a decade and has consulted on and taught Excel best practices to over 400 companies across 30+ countries.