Skip to content

Decimal to fraction converter

Convert a decimal into a simplified fraction, mixed number, and clear calculation steps.

Enter a decimal

Enter a decimal using a point, such as 1.2, 0.125, or -2.75.

Exact result

Enter a decimal, then convert it to a fraction.

How to convert a decimal to a fraction

  1. Enter an ordinary decimal such as 1.2, 0.125, or -2.75.
  2. Select Convert to fraction. The calculator returns a reduced fraction and, when useful, a mixed number.
  3. Read the integer calculation and cross-multiplication check, then copy the plain-text result if you need it elsewhere.

What this converter does

This calculator turns the decimal you actually specify into an exact fraction. It is useful when homework, recipes, ratios, measurements, or written explanations call for fractional notation instead of a rounded decimal. A terminating input such as 0.125 means exactly 125 thousandths. A repeating input such as 0.(3) means that the 3 continues forever. Those are different numbers from a typed approximation such as 0.333, so the repeating part is never guessed.

The result includes a fraction in lowest terms, a mixed-number form, and a compact derivation. Calculations use decimal strings and integers rather than binary floating-point arithmetic. Positive and negative values, zero, leading zeros, and up to 120 decimal digits are supported. This is a focused converter, not an expression engine.

Terminating decimals and place value

For a terminating decimal, count the digits after the point. Remove the point to form the numerator and use 1 followed by that many zeros as the denominator. For example, 2.750 becomes 2750/1000. The greatest common divisor is 250, so dividing both parts by 250 gives 11/4. The displayed mixed number is 2 3/4. Trailing zeros do not change the value, but they do appear in the initial place-value fraction before reduction.

The sign belongs to the complete fraction, so -0.125 becomes -125/1000 and then -1/8. Zero reduces to 0/1. Leading zeros are normalized; 0002.50 and 2.50 have the same result. A period is required in all six languages so a comma cannot silently change meaning.

Example 1: 0.125

There are three decimal places, so 0.125 = 125/1000. The greatest common divisor is 125. Dividing numerator and denominator by 125 gives the exact result 1/8.

Example 2: -2.75

Write -2.75 as -275/100. Divide both values by 25 to get -11/4. As a mixed number, the same value is -2 3/4.

Repeating decimals without guessing

Standard mathematical notation draws a bar over the repeating digits. Because a plain text field cannot easily type that bar, this tool also accepts parentheses as an input convention: 0.(3) represents a bar over the 3. The parentheses are not division and are not presented as universal notation. A typed 0.333 without that marker remains the finite number 333/1000.

The algebra uses two shifted copies of x. If m digits do not repeat and n digits repeat, subtract 10^m·x from 10^(m+n)·x. The infinite tails cancel, leaving an integer divided by 10^m(10^n−1). For 1.2(34), 1000x − 10x = 1222, so 990x = 1222 and x = 611/495. This also handles repeating nines exactly: 0.(9) reduces to 1 and 0.1(9) reduces to 1/5, matching the fact that an infinite tail of nines reaches the next terminating value.

Reading, copying, and checking the result

The simplified fraction is the primary answer; the mixed number is alternate notation. Proper fractions stay in fraction form, whole numbers show an integer, and a negative sign applies to the whole mixed number. The steps show the unreduced fraction and greatest common divisor. Equal cross-products confirm that reduction preserved the value.

Copy result and steps writes plain text such as 1.2(34) = 611/495, plus the mixed number, unreduced fraction, and greatest common divisor. This format works in notes and messages without special fraction fonts. The tool does not create a file, retain a history, or transmit the entered number. If copying is unavailable, select the displayed result manually. Changing the input clears the old answer so a stale result is not mistaken for the new value.

Input limits and common mistakes

Use digits, an optional leading sign, one point, and at most one final parenthesized block. Valid examples include .5, +2.0, -0.00, 0.(142857), and 3.04(5). Do not enter commas, embedded spaces, fractions, percent signs, units, ellipses, expressions, or E notation. An error does not replace the input.

The 120-decimal-digit limit keeps results, steps, and copied text manageable on phones. It is not a precision limit inside that range: every accepted digit participates in exact integer arithmetic. The converter cannot infer whether a displayed calculator result was rounded or whether its last digits truly repeat. Confirm the source value, then add parentheses only when the repeating block is known. For measured quantities, an exact fraction of the typed decimal does not add physical measurement accuracy.

Frequently asked questions

Is 0.333 the same as 0.(3)?

No. 0.333 is the terminating fraction 333/1000. The notation 0.(3) means infinitely many 3s and equals 1/3 exactly. The converter never guesses repetition from matching final digits.

Why does 0.(9) become 1?

An infinite string of nines approaches 1 with no positive gap remaining. The algebra gives 9/9, which reduces to 1. This is an exact identity, not rounding.

How are negative mixed numbers shown?

The sign applies to the whole value. For example, -11/4 is displayed as -2 3/4, meaning negative two and three quarters, not -2 plus a positive three quarters.

Does the calculator approximate long decimals?

No. Accepted digits are converted with BigInt integer arithmetic and then reduced. A finite decimal is treated as exactly the digits entered; a repeating decimal is exact only when its repeating block is marked.

Can I enter a fraction, formula, comma decimal, or E notation?

No. This page converts decimal notation only. Use a period for the decimal point and remove units or expressions. Keeping one unambiguous syntax prevents silent changes across locales.