📖 What is this tool?
Bitwise Calculator performs bit-level operations on integers — AND, OR, XOR, NOT, left shift and right shift. Results are displayed in decimal, binary, hexadecimal and octal, making it essential for low-level programming, embedded systems and flag manipulation.
💡 Example
Input
A=255, Op=AND, B=170
Output
Result: 170
Binary: 10101010
Hex: 0xAA
🛠️ Common Use Cases
- Debug bitwise flag operations in code
- Calculate permission bitmasks
- Understand bitwise operators in programming
- Perform binary arithmetic operations
- Design efficient data encoding schemes
❓ Frequently Asked Questions
What is a bitwise AND operation? ▾
AND compares each bit position of two numbers and returns 1 only if both bits are 1. It's used for masking — checking if specific flags are set in a bitmask.
When would I use XOR in programming? ▾
XOR is used for toggling bits (flip a flag), simple encryption, detecting differences, and classic tricks like swapping two variables without a temp variable.
What is a bitmask? ▾
A bitmask uses individual bits of an integer to store multiple boolean flags compactly. File permissions (rwxrwxrwx), keyboard modifiers and feature flags are classic bitmask uses.
🔒
Your data stays private. All processing happens entirely in your browser. Nothing is ever sent to our servers. You can use this tool offline after the page loads.