Unit Converter

Published Updated

Convert between length, weight, and temperature units instantly, with a full multi-unit comparison table — free and processed entirely in your browser.

Three categories, exact definitions

This converter covers length, weight (mass) and temperature, and it uses the internationally agreed definitions. NIST lists these factors as exact: 1 inch is 2.54 cm, 1 foot is 0.3048 m and 1 mile is 1,609.344 m (NIST SP 811, Appendix B). The pound is 453.59237 g and the ounce is a sixteenth of that, 28.349523125 g.

Length and weight go through a base unit, metres or grams. Temperature goes through Celsius. Results are rounded to 6 decimal places.

How one conversion is computed

For length and weight, the tool multiplies your number by the size of the From unit and divides by the size of the To unit, both expressed in one base unit (metres or grams). Every pair therefore uses two exact factors and a single division, and the only rounding comes from the computer storing the quotient in binary. Temperature goes through Celsius, with the exact formulas NIST publishes: (°F − 32) ÷ 1.8 for Celsius, and Celsius + 273.15 for kelvin (NIST, SI units: temperature). NIST gives zero degrees Celsius as exactly 273.15 K and one Celsius degree as 1.8 Fahrenheit degrees on the same page. The BIPM, which maintains the SI, defines Celsius temperature as t = T − T0 with T0 = 273.15 K, and the degree Celsius as equal in size to the kelvin (BIPM, SI Brochure).

Worked examples

You enterYou read
42.195 km (a marathon)26.218757 miles
70 inches177.8 centimetres
180 pounds81.646627 kilograms
5.5 ounces155.922377 grams
98.6 °F37 °C
-40 °C-40 °F
0 K-273.15 °C

Measured: the raw result and what the page shows

The numbers below were produced by running the converter's own conversion and rounding code in Node. The middle column is the value the computer holds before the 6-decimal rounding, and the last column is what the result box displays.

ConversionRaw valueShown
1 foot to inches12.00000000000000212
350 °F to °C176.66666666666666176.666667
0 K to °F-459.66999999999996-459.67
-300 °C to K-26.850000000000023-26.85
100 m to yards109.36132983377078109.36133
26.2 miles to km42.164812842.164813
500 mg to oz0.0176369809747902070.017637
10 kg to lb22.04622621848775722.046226

The rounding step is what turns 12.000000000000002 into a plain 12. It also means that a rounded answer is not the exact one: 350 °F is 176.666667 °C on screen, while NIST's approximate oven table pairs 350 to 375 °F with 180 to 190 °C. Do not feed a displayed value back in and expect the same number to the last digit. Converting the displayed 37.777778 °C back to °F held 100.0000004 internally and showed 100.

Where the display breaks down

Two limits show up at the ends of the range. A result smaller than 0.0000005 in the chosen unit is shown as 0: 0.0000004 m is 0 in metres, 0 in kilometres and 0.0004 in millimetres. A very large result is shown in exponent form, so 1e21 metres in millimetres appears as 1e+24. Nothing in the converter checks that a temperature is physically possible, which is why -300 °C gives a negative kelvin value.

Using the converter

  1. Step 1

    Pick Length, Weight or Temperature

    Switching category resets the value to 1 and picks the first two units.

  2. Step 2

    Type a number and choose the units

    Use the From and To menus, or the swap button to reverse them. The result updates as you type.

  3. Step 3

    Read the comparison list

    Below the result, the same value is shown in every other unit of that category, so one entry answers several questions.

What it does not cover

  • Volume and area. There are no litres, gallons, square metres or acres.
  • Speed, time and data size. Use the Time Converter for time.
  • US survey units. Feet and miles here are the international ones. NIST says the US survey foot should be avoided from 1 January 2023 (NIST).
  • Fluid ounces. The ounce is the weight (avoirdupois) ounce.

Rounding, and what to do with tiny values

Six decimal places is plenty for everyday work. For very small quantities, pick a smaller unit as the target. 0.0000004 m shows as 0 when you ask for metres, and as 0.0004 when you ask for millimetres.

Unit converter questions

Which units are covered?

Length: metres, centimetres, millimetres, kilometres, inches, feet, yards and miles. Weight: kilograms, grams, milligrams, pounds and ounces. Temperature: Celsius, Fahrenheit and Kelvin. Volume, area, speed and time are not included; for time use the Time Converter.

How accurate are the results?

The factors are the exact international definitions. The only rounding before display comes from the computer's binary arithmetic, which gives 1 foot in inches as 12.000000000000002. The answer is then rounded to 6 decimal places with trailing zeros removed, so it shows 12. A very small result, such as 0.0000004, shows as 0.

Why is a mile 1.609344 kilometres?

Since the 1959 international agreement the yard is exactly 0.9144 m, so a mile of 1,760 yards is exactly 1,609.344 m. The older US survey mile is not used here, and NIST says the US survey foot should be avoided from 2023.

How do I convert 5 ft 10 in?

Convert one unit at a time. Enter 70 inches and read centimetres: 177.8. Or enter 5 feet and 10 inches separately and add the results.

Why does 350 °F show 176.666667 °C and not 180?

The conversion is exact, (350 − 32) ÷ 1.8 = 176.666…, and the box rounds to 6 decimals. Recipes and oven dials use rounder numbers: NIST's approximate table pairs a moderate oven at 350 to 375 °F with 180 to 190 °C. Use the exact figure for science, and the nearest dial setting for cooking.

Why do I not get my original number back when I convert twice?

The box shows a rounded value, so typing that value back in starts from a slightly different number. In a test, 100 °F showed 37.777778 °C, and converting that back to °F gave 100.0000004 before rounding. It displays as 100. Keep the original number instead of chaining displayed results.

What does it show for a very large or very small result?

A result below about 0.0000005 in the chosen unit displays as 0, so pick a smaller unit. A result of 1e21 or more is written in exponent form: 1e21 metres in millimetres shows as 1e+24. Both come from rounding to 6 decimals with JavaScript's number formatting.

Does it stop me entering a temperature below absolute zero?

No. It applies the formula to any number. -300 °C converts to -26.85 K, which is physically impossible. Check your input if you see a negative kelvin.

Related Tools