DuckyTools
Home Developer Bitwise Calculator

Bitwise Calculator Developer

AND, OR, XOR, NOT and shifts on two numbers, shown in every base.

Bitwise Calculator is a free online tool that aND, OR, XOR, NOT and shifts on two numbers, shown in every base. It runs entirely in your web browser using plain JavaScript, so files are processed on your own device and never uploaded to a server. There is no sign-up, no file size limit imposed by the site, no watermark and no paid tier.

Price
Free — no account, no quota, no watermark
Category
Developer
Where it runs
In your browser, on your device
Files uploaded
None
Technology
plain JavaScript
Settings
3
Works offline
Yes, after the first visit

About Bitwise Calculator

JavaScript's bitwise operators coerce their operands to 32-bit signed integers, which produces two behaviors worth knowing: any value above 2³¹−1 wraps to negative, and any number beyond 2³²−1 loses its high bits entirely. That is why `>>>` (unsigned right shift) exists and `>>` preserves the sign bit. Results are shown in binary, hex and decimal so the wrap is visible rather than surprising.

How to use it

  1. Enter a, b and shift amount.
  2. Results update the moment anything changes.

The 3 settings

SettingWhat it doesDefault
AA numeric value.12
BA numeric value.10
Shift amountRange 0–31.2

Under the hood

Runs onplain JavaScript — runs the whole thing
ControlsA, B, Shift amount

Questions

What is the difference between >> and >>>?

`>>` is arithmetic — it copies the sign bit inward, so negative numbers stay negative. `>>>` is logical — it shifts in zeros, so the result is always non-negative. On positive numbers they agree.

Why did my large number give a strange result?

Bitwise operations truncate to 32 bits. Anything above 4,294,967,295 loses its high bits. Use BigInt for larger values, which does not coerce.

What are the limits on shift amount?

It accepts 0 to 31, starting at 2.