Bitwise Calculator

Calculate AND, OR, XOR, NAND, NOR, XNOR, NOT and bit shifts with binary, hex and decimal output. Free, private and instant: everything runs in your browser.

Numbers
Result
Result appears here as you type

What does the Bitwise Calculator do?

A bitwise calculator applies logical operations to each bit of two integers. Enter two numbers in decimal, hex (0x) or binary (0b), choose an operation and bit width, and the tool shows both operands and the result bit by bit plus decimal, signed, hex and octal values.

How to use the Bitwise Calculator

  1. 1

    Enter your values

    Fill in number a and number b at the top of the Bitwise Calculator.

  2. 2

    Choose the options

    Pick operation, bit width, input format.

  3. 3

    Read the result

    The result updates instantly as you type. Copy it or download it as a text file.

When to use it

  • •Working out flag masks in embedded and systems code
  • •Checking the result of shifts and two's complement values
  • •Teaching how logic gates combine bits

Why use this bitwise calculator

  • 100% free, no signup or login
  • Runs locally: your data never leaves the browser
  • Instant results with clear error messages
  • Works on desktop, tablet and mobile
  • Copy to clipboard or download in one click
  • No watermarks and no usage limits

Frequently asked questions

Why does the bit width matter?+

NOT, NAND, NOR and XNOR flip unused high bits, so the result depends on how many bits the number has. Choose the width your program uses, typically 32 or 64.

Is the Bitwise Calculator free?+

Yes. The Bitwise Calculator is 100% free with no signup, no login, no usage limits and no watermark. It works on desktop and mobile browsers.

Is my data uploaded when I use the Bitwise Calculator?+

No. The Bitwise Calculator runs entirely in your browser with JavaScript. Nothing you paste or upload is sent to our servers, logged or stored.

Last updated by the Imaginex AI team.