Skip to content
QueenNexa

Free tool

Scientific Calculator

Calculate with trig in degrees or radians, logs, roots, powers and factorials, using the correct order of operations, with memory, history and keyboard input.

Result

–

Angle mode

Memory: empty

History

    Nothing calculated yet. Press = or Enter. Select a line to reuse it.

    Assumptions and limits

    Nothing is built in except mathematical definitions: every result comes from the expression you enter.

    • Order of operations: parentheses and functions, then ! and %, then ^ (right to left), then unary minus, then × and ÷ (including implicit multiplication such as 2π), then + and −. So -2^2 = -4 and 2^3^2 = 512.
    • Implicit multiplication ranks the same as × and ÷, and operators of equal rank run left to right: 8/2(2+2) is (8 ÷ 2) × 4 = 16. Add parentheses if you mean 8 ÷ (2 × 4).
    • The % sign divides the number before it by 100. It is not a "percent of the total" key.
    • In degrees mode, sin, cos and tan take degrees and asin, acos and atan return degrees. tan(90) is reported as undefined. Tiny trig values below 1e-15 are shown as 0.
    • Results show up to 12 significant digits, which hides binary rounding noise such as 0.1 + 0.2 = 0.30000000000000004. Values of 1e15 or more, or under 1e-6, use exponent form. Factorial works up to 170.
    • Expressions are read by a hand-written parser, never evaluated as code. Memory and history exist only while this page is open.

    Runs entirely in your browser. Nothing you type or upload is sent to our servers.

    How the calculator reads an expression

    Your text is first split into numbers, names and symbols. A parser then reads it by precedence, from the loosest operators (+ and −) down to the tightest (parentheses and function calls), and calculates each part as it goes. Functions such as sin or sqrt take their value from the parentheses after them. Anything the parser does not recognize stops the calculation with a plain-language message instead of a guess.

    Worked example 1: precedence step by step

    Calculate 2 + 3 × 4^2.

    1. The exponent comes first: 4^2 = 16.
    2. Then multiplication: 3 × 16 = 48.
    3. Then addition: 2 + 48 = 50.

    With parentheses, (2 + 3) × 4^2 = 5 × 16 = 80. The calculator opens with 2+3*4^2, so you can press Enter and compare. Also compare -2^2 = -(2 × 2) = -4 with (-2)^2 = 4.

    Worked example 2: degrees and a rounding trap

    1. In degrees mode, sin(30) = 0.5 and cos(60) = 0.5, so sin(30) + cos(60) = 0.5 + 0.5 = 1.
    2. Switch to radians and the same text reads 30 and 60 as radians, so the answer changes. In radians, sin(pi/2) = 1, because pi/2 radians is a quarter turn.
    3. For 0.1 + 0.2, the browser stores the sum as 0.30000000000000004. Rounding to 12 significant digits gives 0.300000000000, which is shown as 0.3.

    Tips

    • Close every parenthesis you open. The calculator reports a missing one rather than guessing.
    • Use Ans to carry the last result into the next calculation, as in Ans * 1.5.
    • For percentages of a total, write the multiplication yourself, such as 200 * 15%, which is 200 × 0.15 = 30.

    Related tools

    For percent change, percent of a number and reverse percentages with the working shown, use the Percentage Calculator. For the area of a shape, open the Area Calculator, and for random values, the Random Number Generator.

    Frequently asked questions

    What order of operations does the calculator use?

    Parentheses and functions first, then factorial and percent, then exponents, then multiplication and division, then addition and subtraction. Operators of the same level go left to right, except exponents, which go right to left. So 2 + 3 × 4^2 is 2 + 3 × 16 = 50, and 2^3^2 is 2^9 = 512. The calculator does not simply work from left to right as a basic pocket calculator might.

    Why does -2^2 give -4 and not 4?

    The exponent binds tighter than the minus sign, so -2^2 means -(2^2) = -4. If you want the square of negative two, write (-2)^2, which is 4. A minus directly after an exponent sign works as expected: 2^-2 is 1 ÷ 4 = 0.25. This is the usual convention in mathematics and in most scientific calculators.

    What is the difference between degrees and radians?

    They are two ways to measure an angle, and the setting changes the answers of sin, cos and tan and the results of asin, acos and atan. In degrees mode, sin(30) = 0.5 and cos(60) = 0.5. In radians mode, sin(30) is about -0.988, because 30 is read as 30 radians. Check the mode shown on the keypad before you start.

    Why does 0.1 + 0.2 show 0.3?

    Computers store most decimals as close binary approximations, and in this browser 0.1 + 0.2 is stored as 0.30000000000000004. The display shows 12 significant digits, which hides that tiny difference and shows 0.3. The value used in later steps is still the stored one, and results beyond 12 digits are not shown, so do not read this as a high-precision calculator.

    How do the % and ! keys work?

    The % key divides the number before it by 100, so 50% is 0.5 and 200 × 10% is 200 × 0.1 = 20. It does not add a percentage to a total as some phone calculators do, so 100 + 10% is 100.1, not 110; write 100 × 1.1 for that. The ! key is factorial for whole numbers from 0 to 170, so 5! is 5 × 4 × 3 × 2 × 1 = 120.

    Is it safe to type any expression? Does it run my text as code?

    The expression is read by a small parser written for this page, which understands only numbers, operators, parentheses, constants and the listed functions. It never runs your text as program code, and anything else, such as a stray word or symbol, is reported as an error. Expressions are limited to 500 characters.

    Which functions and constants are available?

    sin, cos, tan, asin, acos, atan, sinh, cosh, tanh, ln (natural log), log (base 10), sqrt, cbrt, abs and exp, written with parentheses such as sqrt(16). The constants are pi (or π) and e, and Ans is the last result. Powers use ^. Writing 2pi or 3(4+1) multiplies, and it ranks the same as × and ÷.

    Can I use my keyboard, and are memory and history saved?

    Yes. Type into the expression box, press Enter to calculate and Escape to clear. The keypad works by touch and click. Memory (M+, M−, MR, MC) and the last 20 calculations stay on this page only while it is open. They are not saved or sent anywhere, so reloading clears them.

    Link to this tool

    Found it useful? Copy a link for your page, newsletter or documentation.

    Get new tools and guides by email

    Optional. The tool above works without signing up.

    One email every Tuesday. Free, and you can unsubscribe in one click.

    More free tools

    Browse all everyday calculators or the full list of free tools.