Fraction Calculator

Exact fraction arithmetic in the browser — reduced, written as a mixed number, and converted to a decimal.

Runs on your deviceCalculatorsWorkingNo account needed

What this tool does

Fraction Calculator holds every value as a pair of whole numbers, a numerator and a denominator, and never converts to a floating-point number to do the sum. Adding and subtracting go through cross-multiplication, dividing inverts the second value, and the answer is then reduced by the greatest common divisor of its two halves. Both halves are arbitrary-precision integers, so a numerator thirty digits long is added exactly rather than collapsing to the nearest double, and one third comes back as 1/3 instead of 0.3333333333333333.

There are two ways to drive it. Leave the input box empty and the fields beside it take over: choose add, subtract, multiply, divide, compare or simplify, then type the values. Fill the box instead and it wins, with each line read on its own, so a whole worksheet is answered in one pass. A line carries two values and an operator — the typographic + − × ÷ or the plain +, -, *, /, x and : — or a comparison written with <, > or =, or a single value by itself to reduce. Values may be written as 3/4, as the mixed number 1 1/2, as the decimal 0.75, as a whole number, or with a leading minus. Every answer is reported four ways: the expression it came from, the fraction in lowest terms, the mixed number, and the decimal, with a comparison filling those same four columns with both sides and the verdict rather than a single value. The arithmetic happens in this browser tab, so nothing you type is transmitted or stored, and no further network access is needed once the page itself has loaded.

Three hard edges shape what you can ask of it. A line carries exactly two values and one operator, with no brackets and no powers, so 1/2 + 1/4 + 1/8 is rejected rather than chained — a longer sum has to be taken in steps, feeding each answer into the next line. The decimal column truncates instead of rounding: long division runs for the number of digits you asked for, and an expansion still going at that point is marked with an ellipsis, so 2/3 shown to two digits reads 0.66 and not 0.67. And answers arrive already cancelled down, with no working attached, so if what you need is the common denominator or the cancelling step written out, this hands you the destination rather than the route.

How to use it

  1. Pick the operation. Add, subtract, multiply, divide, compare, or simplify the first value. The second field is hidden for simplify, because that one takes a single value.
  2. Type the two fractions. 3/4 for a common fraction, 1 1/2 with a space for a mixed number, 0.75 for a decimal, 5 for a whole number, and a leading minus for a negative.
  3. Or paste a list instead of using the fields. Anything in the input box takes priority. Put one expression on a line and nothing else on it — 1/2 + 3/4, 7/8 ÷ 1 3/4, 12/18, 0.375 — and Load sample fills in a set to try. A leading simplify, reduce or convert is stripped, but a trailing note in brackets is not and will be refused, so keep any remark on its own line starting with # or //.
  4. Set how many decimal digits you want. Anything from 1 to 60, and 10 to begin with. Long division stops at that count, and an expansion that has not terminated is flagged with an ellipsis rather than rounded up.
  5. Read the four columns, or copy them. Expression, fraction, mixed number and decimal come back as a table on the page. Copy output hands you that same table as comma-separated rows under a header line, which is the form a spreadsheet expects.

Processing & privacy

Runs on your device. Your file is processed directly in this browser.

Common use cases

Checking arithmetic homework

Type the sum exactly as it is written and compare the reduced answer and the mixed number against the one on the page. It marks the destination, not the method.

Scaling a recipe up or down

Two thirds of 3/4 of a cup is 1/2 a cup exactly. Multiply the two values and the mixed number column tells you what to actually measure out.

Adding imperial measurements

7/16 in plus 1 3/8 in comes to 1 13/16 in, and the decimal column converts the same figure for a caliper or a digital readout.

Reducing a ratio to compare it

12/18 and 90/120 both collapse to their lowest terms, which is the quickest way to see whether two ratios are in fact the same number.

Turning a decimal back into a fraction

0.375 is read as 375/1000 and reduced to 3/8 — the number a drill bit or a spanner is actually labelled with.

Questions

Do the numbers I type reach a server?
No. The arithmetic runs in this browser tab using the browser's own big-integer support, so no value is transmitted or stored, and once the page has loaded it asks the network for nothing more.
How do I simplify a fraction?
Choose Simplify from the operation list, or put the fraction on a line of its own in the input box. 12/18 comes back as 2/3, with its mixed number and decimal beside it — although a bare fraction on a line is worked out as a division, so the expression column writes it back as 12 ÷ 18.
Does it understand mixed numbers?
Yes, going in and coming out. Type 1 1/2 with a space between the whole number and the fraction and it is read as 3/2, and every result carries a mixed number column.
Why does a decimal end in three dots?
Because the expansion has not finished. The digits shown are truncated rather than rounded, and the ellipsis says there are more of them — 1/3 at five digits is 0.33333 with the ellipsis, never 0.33334.
Can I add three fractions on one line?
No. Each line takes two values and one operator, and there are no brackets. Add the first pair, then put that result on the next line together with the third value.
Does 0.333 become 1/3?
No. A decimal is read literally as a fraction over a power of ten, so 0.333 is 333/1000, which will not reduce any further. Recurring notation is not recognised — type 1/3 if that is what you mean.
What happens with a zero denominator?
The job stops with an error naming the problem, whether the zero is written into a value such as 5/0 or arrives as the second operand of a division.

Related tools