ToolJutsu
All tools
Calculator Tools

Fraction to Decimal Calculator

Convert any fraction to its decimal — or any decimal to its best-fit fraction with mixed number.

Conversion direction

Decimal

0.625

Long form

Reduced fraction

5/8

Already in lowest terms

Mixed number

Proper fraction — no whole part

Calculation steps

  1. 1. Divide numerator by denominator: 5 ÷ 8 = 0.625
  2. 2. Reduce by GCD(5, 8) = 1: 5/8 = 5/8

5/8 = 0.625 (reduced: 5/8)

Quick reference: common fractions

FractionDecimal
1/20.5
1/30.333…
1/40.25
1/50.2
1/80.125
3/80.375
5/80.625
7/80.875
Processed on your device. We never see your files.

How to use Fraction to Decimal Calculator

What this calculator does

This calculator converts a fraction (a numerator over a denominator) into its decimal form, and a decimal into its best-fit fraction. Both directions show the working — the reduced form, the mixed-number form when applicable, and (for decimal-to- fraction) the approximation error so you know how good the fit is.

How to convert a fraction to a decimal

Divide the numerator by the denominator. That’s it.

decimal = numerator ÷ denominator

Example: 5 ÷ 8 = 0.625, so 5/8 = 0.625. The calculator also reduces the fraction (divides both top and bottom by their greatest common divisor) so the simplest equivalent form is visible. 10/16 and 5/8 have the same decimal value (0.625), but 5/8 is in lowest terms.

How to convert a decimal to a fraction

This direction is harder, because the same decimal can be written as many different fractions. 0.5 = 1/2 = 2/4 = 50/100 = 7/14 — all equal, all valid. The calculator uses the Stern–Brocot continued fraction algorithm, which walks a binary tree of all reduced fractions in order of increasing denominator and picks the one closest to your input within a chosen denominator limit.

The max denominator slider is the trade-off lever: larger limits give more accurate fractions but with weirder denominators (355/113 for π); smaller limits give cleaner-looking fractions but worse approximations (22/7).

Worked examples

0.625 → fraction. The calculator returns 5/8. Sanity check: 5/8 = 0.625 exactly. Error reported: 0.

0.3333 → fraction. With max denominator 1 000, returns 1/3 (the closest of all fractions in the search range, error 0.000033…). If you typed exactly 0.3333 and the slider was at 9999, you’d get 3333/9999 = 1/3 after reduction — the algorithm still spots the clean answer.

π (3.14159265358979) → fraction. Max denominator 1 000 returns 355/113, accurate to seven decimal places. Max denominator 100 returns 22/7, accurate to two. The error column quantifies the trade-off so you can pick the right approximation for the context.

Use cases

Woodworking, sewing, drafting. Tape measures, fabric rulers, and construction drawings often use fractions of an inch — 3/16", 5/8", 7/32" — because they correspond to physical markings on the tool. CAD software and 3D printers usually want decimals (0.1875", 0.625", 0.21875"). Converting back and forth is constant work in a shop; this calculator handles both directions without a chart.

Cooking and recipes. A recipe that calls for 2/3 cup of something needs scaling. 2/3 = 0.6667 cups; multiply by your batch factor; convert back to the nearest fraction your measuring set supports. Our Recipe Scaler does the whole pipeline; this calculator does the conversion piece.

Music and rhythm. Note durations are fractions of a beat (1/4, 1/8, 1/16). DAW software stores time signatures and tempo as decimals or rationals. Converting 5/16 to 0.3125 (or vice versa) comes up when programming drum machines or working out polyrhythms.

Repeating vs terminating decimals

A fraction’s decimal terminates if and only if its reduced denominator has no prime factors other than 2 and 5. Otherwise it repeats forever.

FractionReduced denominatorPrime factorsDecimal
1/22{2}0.5 (terminates)
1/44{2}0.25 (terminates)
1/55{5}0.2 (terminates)
1/88{2}0.125 (terminates)
1/33{3}0.3̄ (repeats)
1/66{2, 3}0.16̄ (repeats)
1/77{7}0.1̄4̄2̄8̄5̄7̄ (repeats with period 6)

The “powers of 2 and 5” rule makes sense once you remember decimals are base-10, and 10 = 2 × 5. A fraction with a denominator made only of these primes can always be rewritten over a power of ten.

Why some decimals can’t be exact fractions

Irrational numbers — π, √2, e, the golden ratio φ — have non-repeating, non-terminating decimal expansions and cannot be written as a ratio of two integers. This is a provable result, not just a numerical observation. The Stern–Brocot algorithm can find arbitrarily close fractional approximations (the continued fraction convergents), but the error never reaches zero.

For practical work, the convergents matter: π ≈ 22/7 (error 0.04 %), π ≈ 355/113 (error 8 × 10⁻⁸), √2 ≈ 99/70 (error 7 × 10⁻⁵). These are the best-possible approximations within their denominator limits, which is exactly what the algorithm returns.

Privacy

This calculator performs an integer division (and a GCD search, for reduction) in JavaScript on your device. There are no fetch calls, no analytics on the values you enter, no server-side logging.

Frequently asked questions

How do I convert 0.625 to a fraction?
0.625 is exactly 5/8. The route in: read the decimal as a fraction over a power of ten — 0.625 = 625/1000 — then reduce by the greatest common divisor. GCD(625, 1000) = 125, so 625 ÷ 125 = 5 and 1000 ÷ 125 = 8, giving 5/8. The calculator above uses the Stern–Brocot continued-fraction algorithm, which finds the same answer but works equally well for messier decimals (like 0.3333…1/3) where the over-a-power-of-ten route doesn't reduce cleanly.
What is 1/3 as a decimal?
1/3 = 0.333333… — a repeating decimal. The threes go on forever; no finite decimal representation is exact. Conventionally written as 0.3̄ (with a bar over the 3) or 0.333… with an ellipsis. If you reverse the conversion in this calculator and type 0.333, you'll get back the approximation 333/1000 (which is not exactly one-third) unless your max-denominator slider is at least 3, in which case the algorithm correctly identifies 1/3 as the best fit. This is the trade-off the slider controls.
Why does the calculator say my decimal is approximate?
Many decimals can't be expressed as a fraction with a small denominator. The max-denominator slider caps the search at, say, 1 000 — so for an input like 0.3141592653 (π to 10 places) the calculator returns 355/113, which is the best fraction with denominator ≤ 1 000 and is off by roughly 2.7 × 10⁻⁷. Increase the slider to 10 000 and you'll get a better approximation (312689/99532); decrease it to 100 and you'll get a worse one (22/7). The reported error column shows exactly how far the fraction is from the decimal you typed.
Can every decimal be written as a fraction?
Every rational number can — that's the definition of rational. Irrational numbers (π, √2, e, the golden ratio φ) cannot be written as a fraction of two integers, no matter how large the denominator. They have non-repeating, non-terminating decimal expansions, so the Stern–Brocot algorithm in this calculator can only return progressively better approximations. 22/7 is the classic π approximation (off by 0.04 %); 355/113 is much better (off by 8 × 10⁻⁸). The error never reaches zero for an irrational input.
Is my data uploaded anywhere?
No. The calculator performs an integer division and a GCD computation in JavaScript on your device. The reverse direction runs the Stern–Brocot search locally too. There are no fetch calls, no analytics on the numbers you type, no server-side logging. You can verify in your device's Network panel — once the page has loaded, switching off your internet connection changes nothing about how the calculator behaves.

Related tools