Math Expression Calculator: Type It, Get the Answer
A math expression calculator that works from a single line of text. Type a whole problem such as
150 * 0.20 + 45 and the answer appears under it and updates on every keystroke, so there is no
equals button to find. It follows the order of operations, understands parentheses, powers, percentages,
factorials, square roots, trig and logarithms, and keeps a short history of what you have worked out. It all
runs in your browser and nothing you type is sent anywhere.
How to use the expression calculator
- Type into the Math expression field. On a desktop the field is already focused when the page loads, so just start typing. On a phone it is not, so tap it first.
- Read the Result. The answer sits under the field and changes as you type. Use the clear (X) button in the field to wipe the line and start again.
- Save it if you want it. Press Enter or move out of the field and a finished expression with an answer goes into History.
- Bring an old one back. Press History, then select an entry to put that expression back in the field and carry on from it.
While you are halfway through typing, such as 5 + or (2, the previous answer stays on
screen, dimmed, with a quiet line saying "Keep typing…". You never get an
error flashing at you mid-sentence.
Result: 75
Add a bracket: (150 + 45) * 0.20
Result: 39
Order of operations: why 2 + 3 * 4 is 14
The calculator reads the whole line before it answers, so it applies the order of operations (PEMDAS, BODMAS or
BIDMAS, whichever you were taught): brackets first, then powers, then multiplication and division, then
addition and subtraction. Operators of equal rank run left to right. Many pocket calculators work strictly
left to right as you press keys and would give 20 for 2 + 3 * 4; this one gives 14.
| You type | Result | Why |
|---|---|---|
2 + 3 * 4 | 14 | 3 * 4 first, then + 2 |
(2 + 3) * 4 | 20 | brackets first |
100 - 20 - 5 | 75 | equal rank, left to right |
2^3^2 | 512 | powers group from the right: 2^(3^2) |
-2^2 | -4 | the power is taken before the minus |
2(3+4) | 14 | implicit multiplication, no * needed |
Percentages inside an expression
The % sign turns a number into a fraction of one hundred, so 50% is 0.5. When a
percentage is added to or subtracted from a number, it is taken of that number, the way people say it out loud:
| You type | Result | Meaning |
|---|---|---|
200 + 15% | 230 | 200 plus 15% of 200 |
200 - 10% | 180 | 200 minus 10% of 200 |
15% * 200 | 30 | 15% of 200 |
20% * 150 | 30 | "20% of 150" (the word "of" is not understood) |
Degrees, radians and scientific functions
Without a degree sign the trig functions take radians: sin(pi/2) is 1. Put a
° after the number to give degrees: sin(30°) is 0.5. There is no mode switch to forget
about, because the unit is written into the expression.
- Operators:
+-*/(also × ÷ − and a plain x between numbers),^or**for powers,%,!, ² and ³ - Constants:
pi(or π),eandtau - Roots and powers:
sqrt(or √),cbrt,abs,exp - Trig:
sin,cos,tan,asin,acos,atan,sinh,cosh,tanh - Logarithms:
lnis the natural log,logis base 10, pluslog2andlog10 - Rounding:
floor,ceil,round,trunc; andfactfor factorials
Functions work with or without brackets (sqrt 16 and sqrt(16) are both 4), and capital
letters make no difference. Scientific notation such as 1.5e3 (1500) is accepted.
How the result is shown
Answers are rounded to 12 significant digits, which hides binary rounding noise: 0.1 + 0.2 shows
0.3. Whole numbers stay exact up to 15 digits, and very large or very small values switch to scientific
notation, such as 1E20. The decimal separator follows the language of the page: on a comma-decimal language page
a comma works as the decimal mark, while on English pages 1,000 is read as one thousand.
An expression that is complete but has no real answer, such as 1/0, sqrt(-1),
ln(0), tan(90°) or 171!, shows Undefined with the line "No
number answers this one."
History
The History button shows how many expressions are saved. Open it to see each one with its result, newest first. An expression is saved when you press Enter or leave the field, and only if it has an answer. The list keeps the latest 30, is stored in this browser on this device only, and can be emptied with Clear history.
Frequently asked questions
Does this calculator follow the order of operations?
Yes. It reads the whole expression before answering, so powers come first, then multiplication and division, then addition and subtraction, with equal ranks worked left to right. 2 + 3 * 4 is 14, not 20, and parentheses override the order: (2 + 3) * 4 is 20. Powers are right-associative, so 2^3^2 is 2^9 = 512, and -2^2 is -4 because the power is taken before the minus.
Is the calculator in radians or degrees?
Radians, unless you add the degree sign. There is no mode switch: sin(pi/2) is 1 because pi/2 is read as radians, while sin(30°) is 0.5 because the ° marks 30 as degrees. Type ° after the number (on most keyboards it is Alt+0176 on Windows or Option+Shift+8 on a Mac). The ° works on any number, so 180° is the same as pi radians.
How does the percent sign work: what is 200 + 15%?
A percentage added to or subtracted from a number is taken of that number, so 200 + 15% is 230 and 200 - 10% is 180. On its own, 50% is just 0.5, so 15% * 200 is 30. There is no word 'of', so '20% of 150' is typed as 20% * 150, which gives 30.
Can I use parentheses and exponents in an online calculator?
Yes, both. Group with ( ), as deep as you need, and write powers with ^ or **: 2^10 and 2**10 both give 1024. The squared and cubed signs ² and ³ work too, and square roots can be written sqrt(16), sqrt 16 or √16. Implicit multiplication is understood, so 2(3+4) is 14 and 2pi is 6.28318530718.
Can I see my calculator history online?
Yes. Press Enter in the field or leave the field and a finished expression with an answer is saved. The History button shows how many are saved, and opens the list with each result, newest first. It keeps the last 30 and stores them only in this browser, on this device. Select an entry to put it back in the field, or press Clear history to empty the list.
Why does it say Undefined?
Because the expression is complete but no real number answers it. Dividing by zero (1/0), the square root of a negative number (sqrt(-1)), ln(0), tan(90°) and factorials past 170! all show Undefined with the note 'No number answers this one.' That is different from an unfinished expression such as 5 + or (2, which keeps the previous answer dimmed and shows 'Keep typing…'
How do I calculate a factorial?
Put ! after the number: 5! is 120 and 10! is 3628800. You can also write fact(5). Factorials work up to 170!, because 171! is larger than any number the calculator can hold and shows Undefined. Long results switch to scientific notation, as with any large number.
Does it solve equations or use variables like x?
No. It evaluates an expression made of numbers, so it works out 3 * (4 + 5) but it cannot solve for x, simplify algebra or take variables. There are also no functions with several arguments (no min, max or pow(a, b)), no unit conversion and no mod. A plain x between two numbers is read as multiplication, so 6 x 7 is 42.
Is what I type sent anywhere?
No. The expression is read and worked out by the page in your own browser. It never uses eval and sends nothing to a server. The only thing stored is your history, in this browser's local storage on this device.
Recommended
-
TI-30XS MultiView Scientific CalculatorIts four-line display shows the whole expression, just like the field above.
-
Casio fx-9750GIII Graphing CalculatorPlot the functions behind your answers, with Python built in.
-
Amazon Basics Aluminum Laptop StandRaise the screen for long homework or budgeting sessions.
Helps keep the tools free. ✨
Images are for illustration only. As an Amazon Associate I earn from qualifying purchases.