Type the whole calculation the way you would write it — 2 + 3 × (4 − 1)^2 — and the result updates as you type. Brackets, powers, roots, logarithms, trigonometry in degrees or radians and factorials are all supported, along with π and e. Press Enter to keep a result and it goes into the history, ready to be reused.
Type it as you would write it. ×, ÷, − and a decimal comma are accepted. Enter keeps the result.
Start typing an expression to see the result.
How it works
The expression is parsed rather than executed: it is broken into tokens, converted to postfix form with the shunting-yard algorithm and then evaluated. Nothing you type is ever run as code, which is why an unknown word gives you a clear message instead of a strange result, and why the calculator can tell the difference between a syntax problem, an unbalanced bracket and a value outside a function domain.
Precedence follows the usual mathematical rules, including the parts people disagree about. Powers bind tighter than unary minus, so −2^2 is −4, and powers are right-associative, so 2^3^2 is 2^9 = 512 rather than 8^2. Multiplication and division bind tighter than addition and subtraction, and both associate left to right, so 10 − 3 − 2 is 5.
Implicit multiplication is accepted where it is unambiguous: 2(3+4), 2π and 3sqrt(16) all work. You can type ×, ÷ and − as well as the ASCII forms, and a decimal comma is read as a decimal point, so 1,5*2 gives 3. Results avoid floating-point noise — 0.1 + 0.2 shows as 0.3 rather than 0.30000000000000004 — and switch to scientific notation only for genuinely huge or tiny numbers.
Practical examples
An expression with brackets and a power
Typing 2+3*(4-1)^2 gives 29: the bracket first, then the square, then the multiplication, then the addition. No need to calculate the pieces separately.
Trigonometry in degrees
With degrees selected, sin(30) is 0.5 and cos(180) is −1. Switch to radians and sin(pi/2) is 1 — the same keys, the mode decides how the angle is read.
Combinations by hand
The number of ways to pick 5 from 10 is 10!/(5!*5!) — type it exactly like that and the answer is 252.
Compound interest in one line
1000*(1+0.05)^10 gives 1628.89462678 — the value of 1,000 at 5% a year for ten years, without a dedicated calculator.
Frequently asked questions
Why is −2^2 negative?
Because exponentiation binds tighter than the minus sign, so it reads as −(2²) = −4. If you mean the square of negative two, write (−2)^2, which gives 4. Most scientific calculators and programming languages behave the same way.
What does 2^3^2 evaluate to?
512. Powers are right-associative, so it is 2^(3^2) = 2^9. Writing (2^3)^2 gives 64 instead.
Which functions can I use?
sin, cos, tan and their inverses asin, acos, atan; the hyperbolic sinh, cosh, tanh; ln, log (base 10), log2; sqrt, cbrt, abs, exp, sign, round, floor and ceil. Plus the postfix factorial (5!) and mod for remainders.
Do the trigonometric functions use degrees or radians?
Whichever you select — degrees by default, since that is what most people type. The setting affects sin, cos and tan on the way in, and asin, acos and atan on the way out.
Can I write 2π or 2(3+4) without a multiplication sign?
Yes. A number directly before a constant, a function or an opening bracket is treated as multiplication. What you cannot do is write two numbers in a row — 2 3 is a syntax error rather than a guess.
Does it accept the decimal comma?
Yes, a comma is read as a decimal point, so 1,5*2 is 3. That also means a comma cannot be used as a thousands separator or an argument separator.
Why does sqrt(−4) give an error rather than a complex number?
Because the calculator works with real numbers, so a negative square root is outside the domain. The same applies to ln(0) and asin(2) — the error names the problem instead of quietly returning NaN.
What is the largest factorial it can compute?
170! — 171! exceeds the largest number a browser can represent, so it reports an overflow rather than showing Infinity.
Why does the result sometimes appear in scientific notation?
Below 0.0000001 or from 10^15 up, plain digits stop being readable, so the result switches to exponential form. Inside that range you always get ordinary notation.
How does the history work?
Pressing Enter or the equals button stores the expression and its result, and clicking a history row puts that expression back in the field. The result is also placed in the input, so you can carry on calculating from it.
Can I trust it for exam-style work?
The arithmetic follows standard precedence and IEEE double-precision numbers, the same as a handheld scientific calculator. It is a tool, not a permission slip — check whether your exam allows one at all.
Is my expression sent anywhere?
No. Parsing and evaluation happen in your browser; nothing you type leaves the page.
Related tools
Percentage Calculator
Calculate X% of a number, what percent one number is of another, and percentage change.
Everyday calculators
Exponent Calculator
Raise any base to any power — including negative and fractional exponents. Runs in your browser.
Math & education
Logarithm Calculator
Find the logarithm of a number in any base, plus natural log, log₁₀ and log₂. Runs in your browser.
Math & education
Fraction Calculator
Add, subtract, multiply and divide fractions and mixed numbers, with the result reduced to lowest terms.
Math & education
Scientific Notation Converter
Convert numbers to and from scientific notation, E notation and engineering notation.
Math & education
Regex Tester
Test a JavaScript regular expression against text and see every match, with numbered and named capture groups.
Developer tools