Convert numbers across binary, octal, decimal, hexadecimal, Base64, or a custom radix.

Result

Run the tool to see the result here

Overview

Base Converter is a versatile number system conversion tool supporting bases from 2 (binary) to 64 (custom radix). It instantly converts any integer between binary, octal, decimal, hexadecimal, Base64, and custom bases. Essential for low-level programming, data encoding, cryptography, and understanding how computers represent numbers internally. The tool provides simultaneous conversion to all common bases for quick comparison.

Use Cases

Programming and Bitwise Operations

When working with bitwise operations, bit flags, or binary protocols, convert between binary and hexadecimal representations to visualize bit patterns. This is invaluable for debugging low-level code, understanding bit masks, and working with embedded systems or network protocols.

Color Code Conversion

Convert decimal RGB values to hexadecimal color codes for web development. For example, convert RGB(255, 165, 0) component values to their hex equivalents (#FF, #A5, #00) to construct complete color codes. This bridges the gap between design tools and CSS.

Data Encoding and Compression

Understand how data is encoded in different bases for various purposes. Base64 encoding is common in email attachments and data URIs, while higher bases are used in URL shorteners and compact identifiers. Convert between bases to analyze encoded data or choose optimal encoding strategies.

Computer Science Education

Learn how different number systems work and how computers represent numbers. Convert the same value across multiple bases to understand place value, digit representation, and the mathematical relationships between different numeral systems. Perfect for students and educators.

Hexadecimal Memory Addresses

Convert memory addresses from hexadecimal (commonly used in debuggers and memory dumps) to decimal for calculations or to binary for bit-level analysis. This is essential when debugging, analyzing core dumps, or working with memory-mapped hardware.

How to Use

  1. Enter your number and source base

    Type or paste the number you want to convert into the input field. Select the base (radix) of your input number from the dropdown - choose from common options like Binary (2), Octal (8), Decimal (10), Hexadecimal (16), or specify a custom base between 2 and 64.

  2. Click Convert number

    Press the Convert number button to perform the conversion. The tool will automatically validate your input and convert it to all supported number bases simultaneously.

  3. Review all base representations

    Examine the results showing your number in Binary, Octal, Decimal, Hexadecimal, Base64, and optionally a custom base. Each conversion includes the base/radix number in parentheses for clarity. Click any result to copy it to your clipboard.

Frequently Asked Questions

What is the difference between Base64 and base 64?

Base64 (capital B) is a specific encoding scheme using 64 characters (A-Z, a-z, 0-9, +, /) commonly used for encoding binary data. "Base 64" (lowercase) refers to any numeral system with a radix of 64, which could use different character sets. This tool shows Base64 encoding results specifically.

What bases are most commonly used in programming?

Binary (base 2) represents bits and is fundamental to all computing. Octal (base 8) was historically used in Unix permissions. Decimal (base 10) is our everyday number system. Hexadecimal (base 16) is widely used for memory addresses, color codes, and compact binary representation. Base64 is common for encoding binary data in text formats.

Can I convert negative numbers or decimals?

This tool currently supports positive integers only. Negative numbers and fractional values require different representation schemes (like two's complement for negatives or fixed/floating-point for decimals) that vary by implementation. For these cases, use specialized tools or programming language functions.

What characters are valid for each base?

Binary (base 2) uses 0-1. Octal (base 8) uses 0-7. Decimal (base 10) uses 0-9. Hexadecimal (base 16) uses 0-9 and A-F. Higher bases typically use 0-9, A-Z, a-z, and additional symbols. The tool will validate your input and show an error if you use invalid characters for the selected base.

Why would I use a custom base like 36 or 62?

Custom bases are useful for creating compact, URL-safe identifiers. Base 36 (0-9, A-Z) and Base 62 (0-9, A-Z, a-z) are popular for URL shorteners, generating short codes, and creating case-sensitive identifiers with maximum information density in the fewest characters.

Related Tools

External Resources