Bitwise Calculator

Perform bitwise operations (AND, OR, XOR, NOT, shift left, shift right) on two integers. Useful for low-level programming and digital logic design.

isCalculator Editorial Team Published by:
Reviewed by: Review Board
Last Updated:

Was this calculator helpful?

How to use this tool?

This calculator performs bitwise operations on two integers. Follow these steps:

  1. Enter the first integer in the "First Integer" field (e.g., 12).
  2. Enter the second integer in the "Second Integer" field (e.g., 5). This field is disabled when "NOT" is selected.
  3. Choose an operation from the dropdown:
    • AND, OR, XOR — standard bitwise operations on both numbers.
    • NOT — inverts the bits of the first integer only.
    • Left Shift / Right Shift — shifts the first integer by the second integer’s value.
  4. Click "Calculate" or press Enter in any input field.
  5. The result shows:
    • The integer result (e.g., 4).
    • The binary representation (e.g., 100).
    • A detail line showing the operation (e.g., 12 & 5 = 4).

All inputs must be integers. The "NOT" operation disables the second input automatically.

Previous Results

Generate Charts
Result Inputs Date

Frequently Asked Questions

A bitwise operation operates on one or more bit patterns or binary numerals at the level of their individual bits. Common operations include AND, OR, XOR, NOT, and bit shifts.

The NOT operation flips all bits of the number. In JavaScript, ~x returns -(x+1) because of two's complement representation. For example, ~5 = -6.

Yes, the calculator accepts negative integers. Bitwise operations treat numbers as signed 32-bit integers in JavaScript.

Quick Convert
Length Converter
0
Weight/Mass Converter
0
Area Converter
0
Volume Converter
0
Speed Converter
0
Temperature Converter
0
Pressure Converter
0
Energy Converter
0
Power Converter
0
Force Converter
0
Time Converter
0
Angle Converter
0
Fuel Consumption Converter
0
Data Storage Converter
0
Base Numbers Converter
0
Dry Volume Converter
0
Currency Converter
0
Text Case Converter
0