Number Base Converter
Convert between binary, octal, decimal, hex.
Overview
Converts a number between bases, such as binary, octal, decimal, and hexadecimal. Useful for low-level programming, working with colors or bit flags, and any time you need the same value in a different base. It runs in your browser.
How it works
The same quantity can be written in different number systems, or bases. Decimal uses ten digits, binary uses two, octal eight, and hexadecimal sixteen (0 to 9 plus A to F). The tool reads the number you enter in its base and re-expresses the identical value in the others, doing the conversion arithmetic for you.
How to use it
- Enter your number and select its base.
- The tool converts it to the other bases.
- Read the equivalent values.
- Copy the representation you need.
Examples
Decimal to hex and binary
The decimal number 255 is FF in hexadecimal and 11111111 in binary.
Hex color to decimal
Convert a hex value into decimal when you need its numeric form.
FAQ
What is a number base?
Why is hexadecimal common in programming?
Does converting change the value?
Is my data uploaded?
Related tools
JSON Formatter
Format, validate, beautify, and minify JSON.
Open toolBase64 Encoder and Decoder
Encode text to Base64 or decode it back.
Open toolPassword Generator
Generate strong random passwords with length and character options.
Open toolUUID Generator
Generate v4 UUIDs in bulk.
Open toolURL Encoder and Decoder
URL-encode or decode percent-encoded strings.
Open toolEmbed this tool
Paste this snippet to put the tool on your own site. It runs entirely in the visitor's browser, the same as it does here.