Decimal
Hexadecimal
Binary
Octal
ASCII

Interactive Bits (click to toggle)

Quick Operations

Bitwise Calculator

Result

Number Base Reference

Base Prefix Digits Example
Binary (2)0b0-10b1010 = 10
Octal (8)0o0-70o12 = 10
Decimal (10)(none)0-910
Hexadecimal (16)0x0-9, A-F0xA = 10

Bitwise Operations

Operation Symbol Description Example
AND&1 if both bits are 11010 & 1100 = 1000
OR|1 if either bit is 11010 | 1100 = 1110
XOR^1 if bits are different1010 ^ 1100 = 0110
NOT~Inverts all bits~1010 = 0101
Left Shift<<Shift bits left (×2)0010 << 1 = 0100
Right Shift>>Shift bits right (÷2)0100 >> 1 = 0010