WebToolsPlanet
Developer Tools

AND Calculator

Enter two numbers and instantly compute their bitwise AND result in decimal, binary, hex, and octal.

Last updated: May 29, 2026

Client-Side Processing
Input Data Stays on Device
Instant Local Execution

Find this tool useful? Support the project to keep it free!

Buy me a coffee

What is AND Calculator?

AND Calculator computes the bitwise AND operation between two integers. It accepts input in decimal, binary, hexadecimal, or octal and returns the result in all four bases. A visual bit-pattern diagram shows how AND is applied bit by bit. The calculator uses unsigned 32-bit arithmetic (operands are coerced with >>> 0), consistent with how JavaScript and most embedded systems handle bitwise operations.

How to Use AND Calculator

1

Select the input base.

2

Enter two numbers.

3

The AND result appears in all four bases below.

Common Use Cases

  • Extracting specific bits from a register value using a bitmask.
  • Checking whether specific flags are set in a bitfield.
  • Computing subnet masks in networking calculations.
  • Verifying bitwise AND behavior for hardware register programming.

Example Input and Output

12 AND 10 in decimal.

A=12, B=10 (decimal)
A: 12 (1100₂)
B: 10 (1010₂)
Result
AND: 8 (1000₂)

Privacy

All calculations run locally in the browser.

Frequently Asked Questions

What does bitwise AND do?
Bitwise AND compares each bit position of two operands. The result bit is 1 only when both corresponding input bits are 1. All other bit positions produce 0.
Why does the result use unsigned 32-bit?
Bitwise operators in JavaScript convert operands to signed 32-bit integers before operating, then >>> 0 converts the result to unsigned 32-bit for display. This matches the behavior in C/C++ unsigned int operations.
Is my data uploaded anywhere?
No. All calculation runs in your browser.