Decimal to Fraction Converter

Convert a decimal inch to the nearest machinist fraction (1/8 down to 1/128), reduced to lowest terms, with the exact-vs-approximate difference shown. Runs in your browser.

Nearest fraction

-

How it works

Machinist fractions use power-of-two denominators (halves, quarters, eighths, and so on). This tool multiplies your decimal by the chosen denominator, rounds to the nearest whole numerator, then reduces to lowest terms:

numerator = round(decimal × denominator)

A finer denominator (like 1/64" or 1/128") snaps closer to the true value. When the fraction lands exactly on the decimal, it is marked as an exact match.

What this does

This tool converts a decimal inch to the nearest machinist fraction (from 1/8 down to 1/128) reduced to lowest terms, and shows how far the fraction is from the exact decimal.

How to use it

  1. Enter a decimal inch value.
  2. Choose the smallest denominator to allow.
  3. Read the nearest fraction and the rounding error.

How it works

The decimal is multiplied by your chosen denominator (such as 64), rounded to the nearest whole numerator, then reduced to lowest terms. Imperial fractions use powers of two because rulers and tooling subdivide by halving.

numerator = round(decimal × denominator)

Example

0.375 inch becomes exactly 3/8 inch. 0.51 inch rounds to 33/64 inch, which is about 0.0006 inch over.

Sources & methodology

Last updated .

Frequently asked questions

How is the nearest fraction found?

The decimal is multiplied by your chosen denominator (such as 64), rounded to the nearest whole numerator, then reduced to lowest terms, so 0.375" becomes 3/8".

Why are denominators always powers of two?

Machinist and imperial fractions subdivide by halving (halves, quarters, eighths, sixteenths, and so on) which keeps rulers, drills, and tooling consistent.

Is my data stored?

No. Everything is calculated locally in your browser.