Number Base Converter (Binary, Hex, Decimal, Octal)

Type a number and choose its base to see it in binary, octal, decimal and hexadecimal at once. Works with very large numbers too.

🔒 Everything you type stays in your browser. Nothing is sent to a server.

By Shah Rukh, software developer · Last updated:

How to convert decimal to binary

Divide by 2 repeatedly and write down the remainders from bottom to top. For 13: 13 ÷ 2 = 6 r 1, 6 ÷ 2 = 3 r 0, 3 ÷ 2 = 1 r 1, 1 ÷ 2 = 0 r 1, so 13 = 1101.

Quick reference

DecimalBinaryHexOctal
1111
81000810
101010A12
151111F17
16100001020
25511111111FF377

Prefixes like 0x (hex), 0b (binary) and 0o (octal) are accepted and ignored.

Frequently asked questions

Why do programmers use hex?

One hex digit equals exactly 4 binary digits, so hex is a compact way to write binary, like colour codes #FF0000.

Is there a size limit?

No practical limit. It uses arbitrary-precision integers (BigInt).

Does it handle fractions?

No, whole numbers only.

Related tools

🔳

QR Code Generator

Free QR codes for links, Wi-Fi, text and contacts.

🏗️

Discord Server Template

Design channels and roles, then build them in one click.

🛡️

Discord Moderation Bot

Make your own mod bot with kick, ban, mute and filters.

🤖

Discord Bot Maker

Build a custom Discord bot without coding.

👋

Discord Welcome Bot

Custom welcome messages and auto-roles for new members.

🎨

Color Picker & Palette

HEX, RGB and HSL codes plus matching palettes.

See all Developer Tools →