Hex to Decimal Converter
Convert hexadecimal (base 16) numbers to decimal (base 10) instantly. Supports single values, batch conversion, and accepts input with or without 0x prefix.
๐ Need the opposite?
Convert decimal to hexadecimal instead
๐ Quick Reference Table:
| Hexadecimal | Decimal |
|---|---|
| 0x0 | 0 |
| 0xA | 10 |
| 0xF | 15 |
| 0x10 | 16 |
| 0x64 | 100 |
| 0xFF | 255 |
| 0x100 | 256 |
| 0x3E8 | 1000 |
| 0xFFF | 4095 |
| 0xFFFF | 65535 |
๐ก Quick Guide:
- Hexadecimal: Base 16 number system using digits 0-9 and letters A-F
- 0x Prefix: Optional prefix used in programming (e.g., 0xFF or just FF)
- Batch Conversion: Convert multiple values at once separated by commas or new lines
- Case Insensitive: Works with both uppercase (FF) and lowercase (ff) letters
About Hex to Decimal Converter
Our free online hex to decimal converter makes it easy to convert hexadecimal numbers to decimal format. Whether you're debugging code, working with memory addresses, analyzing color codes, or learning number systems, this tool provides instant, accurate conversions.
Key Features
- Instant Conversion: Convert hex to decimal in real-time
- Flexible Input: Accepts values with or without 0x prefix
- Batch Processing: Convert multiple hex values at once
- Case Insensitive: Works with both uppercase and lowercase hex digits
- Large Number Support: Handles hex values of any size
- Quick Reference Table: See common conversions at a glance
- Copy to Clipboard: One-click copy for easy use
- No Formatting Required: Automatically handles commas, spaces, and line breaks
How to Convert Hex to Decimal
- Enter Hex Value: Type or paste hexadecimal numbers (e.g., FF, 0x1A3, DEADBEEF)
- Multiple Values: Separate multiple values with commas, spaces, or new lines
- Convert: Click "Convert to Decimal" button
- View Results: See the decimal equivalents instantly
- Copy: Use the copy button to use results in your work
Understanding Hexadecimal Numbers
Hexadecimal (hex) is a base-16 number system that uses 16 distinct symbols: the digits 0-9 represent values zero to nine, and the letters A-F represent values ten to fifteen. Each hex digit represents 4 bits (binary digits), making hex a compact way to represent binary data.
The 0x prefix is commonly used in programming languages like C, C++, Java, JavaScript, and Python to denote hexadecimal literals. For example, 0xFF represents the decimal value 255. This converter accepts hex values with or without this prefix.
Conversion formula: Each hex digit position represents a power of 16. For example, 0x2A3 = (2 ร 16ยฒ) + (10 ร 16ยน) + (3 ร 16โฐ) = 512 + 160 + 3 = 675 in decimal.
Common Use Cases
- Programming: Convert hex constants, error codes, and memory addresses to decimal
- Color Codes: Understand RGB color values (e.g., #FF5733 = R:255, G:87, B:51)
- Debugging: Analyze hex dumps, memory addresses, and register values
- Networking: Convert MAC addresses and IP addresses from hex format
- File Analysis: Interpret hex values in binary files and data structures
- Cryptography: Work with hash values and encrypted data
- Education: Learn number systems and practice base conversions
Hexadecimal Digit Reference
Hex Digits: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F
Decimal Values: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15
Remember: A=10, B=11, C=12, D=13, E=14, F=15. These letter-digit mappings are fundamental to hex conversions.
Conversion Examples
Example 1: 0xFF converts to 255
Calculation: (15 ร 16) + 15 = 240 + 15 = 255
Example 2: 1A3 converts to 419
Calculation: (1 ร 256) + (10 ร 16) + 3 = 256 + 160 + 3 = 419
Example 3: DEADBEEF converts to 3735928559
A common test value in programming and debugging
Example 4: Multiple values: 0x10, 0x20, 0xFF converts to 16, 32, 255
Tips for Using This Converter
- The 0x prefix is optional - "FF" and "0xFF" both work
- Hex values are case-insensitive - "ff", "FF", and "Ff" all convert to 255
- Separate multiple values with commas, spaces, or put them on separate lines
- The tool automatically filters out invalid characters
- Use the quick reference table for common conversions
- Perfect for converting color codes: #RRGGBB format
Hexadecimal in Programming
C/C++: int value = 0xFF; // 255 in decimal
JavaScript: const color = 0xFF5733; // RGB color value
Python: value = 0xDEADBEEF # Common test value
CSS Colors: #FF5733 is equivalent to RGB(255, 87, 51)
Why Use Hexadecimal?
- Compact Representation: 1 hex digit = 4 bits, making it more compact than binary
- Easy Binary Conversion: Each hex digit directly maps to 4 binary digits
- Human Readable: More readable than long binary strings
- Byte Alignment: 2 hex digits = 1 byte, perfect for memory representation
- Standard Format: Widely used in computing, networking, and electronics
Privacy and Security
All conversions are performed entirely in your web browser using JavaScript. No data is sent to any server, ensuring your values remain completely private and secure.