Unit Converter
Convert between 12 categories of unit
Length, mass, volume, area, temperature, speed, time, data and more — bidirectional, instant, exact.
Unit Converter
Runs in your browser · nothing uploaded| Unit | Symbol | Value |
|---|---|---|
| Kilometre | km | 0.1 |
| Centimetre | cm | 10,000 |
| Millimetre | mm | 100,000 |
| Micrometre | µm | 100,000,000 |
| Nanometre | nm | 100,000,000,000 |
| Mile | mi | 0.0621371 |
| Yard | yd | 109.361 |
| Foot | ft | 328.084 |
| Inch | in | 3,937.01 |
| Nautical mile | nmi | 0.0539957 |
| Light year | ly | 1.05700e-14 |
| Astronomical unit | au | 6.68459e-10 |
Factors are exact where the definition is exact: an inch is precisely 25.4 mm, a pound precisely 0.45359237 kg. 12 categories, 101 units.
01 — How to use Unit Converter
02 — Getting good results
03 — Questions
No. The conversion factors are built into the page and the arithmetic happens in this browser tab. Nothing is transmitted or stored.
Exact where the definition is exact. An inch is defined as precisely 25.4 mm and a pound as precisely 0.45359237 kg, so those conversions are not approximations. Where a unit is defined by measurement rather than definition, the full published precision is used.
Because months have no fixed length. The figure used is the average Gregorian month, which is the only sensible constant, but converting a specific month is a calendar question rather than a unit one — the date calculator handles that properly.
Floating-point arithmetic rounds at each step, so a value taken through two conversions can differ in the last decimal place. The displayed precision hides it, and the difference is far below any real-world measurement error.
04 — More about Unit Converter
Why conversion goes through a base unit
A category with twenty units has 380 ordered pairs, and storing a factor for each would mean 380 chances to get one wrong and 380 entries to update when a definition changes. Converting through a base unit instead needs one factor per unit — twenty numbers — and derives every pair at runtime by dividing one by the other. The structural benefit is that adding a unit is a single line rather than a new row and column, and the correctness benefit is that inconsistent pairs become impossible: with per-pair factors, it is entirely possible for A-to-B and B-to-A to disagree, and for a chain through C to give a third answer. Going via a base makes that class of bug unrepresentable.
The affine exception
Almost every unit conversion is a pure ratio, which is why the base-unit approach works so cleanly. Temperature breaks it, because the scales do not share an origin: 0 °C is 32 °F, so scaling alone can never convert between them. The fix is to treat every unit as an affine map rather than a ratio — multiply by a factor and add an offset — where the offset happens to be zero for all the ordinary units. One conversion function then covers everything, and temperature stops being a special case that every caller has to remember. It is a small design decision that removes an entire category of bug: the tools that get temperature wrong are usually the ones that bolted it onto a ratio-only converter afterwards.
61 more tools
where this came from.
Same shell, same shortcuts, same promise: nothing leaves your browser.