Binary Calculator

Convert between decimal and binary number representations.

Calculate

Enter your values below.

Result

Result
0

Formula used

Decimal-to-binary conversion repeatedly divides by 2, recording remainders; binary-to-decimal sums each digit times its power of 2.

Example: 42 in decimal = 101010 in binary.

How to use this calculator

  1. Enter Decimal number, Binary number.
  2. Choose Direction.
  3. Press Calculate to see your result instantly.

Frequently asked questions

What is binary?

A base-2 number system using only the digits 0 and 1 — the foundation of digital computing.

Can I convert negative numbers?

This tool covers non-negative integers; negative binary representations (like two's complement) vary by bit width.

What characters are valid in a binary number?

Only 0s and 1s.

How large a number can I convert?

Any value JavaScript can represent as a safe integer.