Basic calculator
Fast arithmetic with history and keyboard support.
A fast, free basic arithmetic calculator for everyday use — addition, subtraction, multiplication, and division — with full keyboard support, a running history stored locally on your device, and dark mode for late-night work. Designed for quick mental-math sanity checks and simple budgeting without the overkill of a spreadsheet.
Tips for using the basic calculator
Type directly with your keyboard. Number keys 0–9, the operators +, −, *, /, the decimal point, Enter (or =) to compute, and Backspace to delete the last digit are all wired up. Escape clears the current expression; pressing C twice clears the entire memory.
Each completed calculation is appended to the history panel on the right. Click any previous entry to recall it as the current expression — useful when you want to chain a follow-up operation on a recent result.
History is stored only in your browser's local storage on this device. It never leaves your machine, never syncs to a server, and is cleared if you wipe your browser data. There is also a one-click 'Clear history' button at the top of the panel.
On mobile, the on-screen keypad responds to taps with the same key behaviour. The order-of-operations on this calculator is strictly left-to-right — for parentheses, exponents, or precedence-sensitive math, use the scientific calculator instead.
How the basic operators behave
Addition (+) and subtraction (−) work as expected for both integers and decimals.
Multiplication (× or *) and division (÷ or /) follow left-to-right evaluation. Pressing '2 + 3 × 4 =' on this calculator yields 20, not 14 — because each operator is applied immediately to the running total.
Division by zero displays 'Error' and clears the operand. The next key resets the calculator.
Decimal precision uses JavaScript's IEEE-754 doubles, accurate to about 15 significant digits. Use the scientific calculator for higher-precision work.
Frequently asked questions
- Does my history sync across devices?
- No. History is stored only in your browser's local storage on this device. There is no account system and the data never leaves your machine.
- How accurate is the arithmetic?
- Calculations use JavaScript's IEEE-754 double-precision floats, which are exact for integers up to 2^53 and roughly 15–17 significant digits for decimals. For typical everyday use this is more than enough; for cryptographic-grade or financial-regulation work, use a fixed-point or decimal library instead.
- Why does '2 + 3 × 4' give 20 instead of 14?
- This calculator applies each operator immediately to the running total — the same behaviour as classic physical pocket calculators. There is no operator-precedence resolution. For PEMDAS-style math with parentheses and exponents, switch to the scientific calculator.
- Can I copy a result?
- Yes. Tap or click on the result display to select it, then copy with Cmd/Ctrl-C. The history panel also exposes individual entries for copy.
- Does the calculator work offline?
- Once the page is loaded, the calculator runs entirely in your browser — no internet connection is needed to compute, save history, or change themes. Bookmark the page for quick offline access.