Skip to content
Email signature generator update - check out new features tools
Arteon - company logo
#MadeWithNext.js
Arteon logo

Free online tools for web developers, designers, and marketers.

Tools

  • Online image editor
  • Favicon generator
  • Meta title & description checker
  • Word & character counter
  • Lorem Ipsum Generator
  • Email signature generator
  • Color contrast checker
  • Image color extractor
  • Color palette generator

Tools

  • Free QR code generator
  • pt to px
  • rem to px
  • em to px
  • cm to px
  • mm to px
  • inches to px
  • DPI to PPI
  • HEX to RGB

Tools

  • RGB to HSL
  • RGB to CMYK
  • bytes to KB/MB/GB
  • Unix to date
  • DEC to BIN
  • DEC to HEX
  • Mbps to MB/s
  • vw to px
  • Tailwind CSS spacing to px

Tools

  • JPG to WebP
  • PNG to WebP
  • WebP to JPG
  • WebP to PNG
  • PNG to JPG
  • JPG to PNG
  • SVG to PNG
  • BMP to JPG
  • JPG to AVIF

Legal documents

  • Privacy Policy
  • Terms of Service
© 2025 Arteon. All rights reserved.#MadeWithNext.js

Convert decimal to hex – CSS colors and code values

255 = FF. 65535 = FFFF. Convert any decimal to hex — or hex back to decimal — instantly for web colors, debugging, and Unicode lookups.

  1. /Tools
  2. /dec to hex
ADVERTISEMENT
ADVERTISEMENT
Loading tool editor...
Decimal to hexadecimal converter – Arteon

When do you need to convert decimal to hexadecimal?

Hexadecimal (base-16) uses digits 0–9 and letters A–F. It is a compact way to represent binary data: each hex digit = 4 bits. This makes hex essential for programming, web colors, and memory addresses.

Web colors use hex: #FF5733 = red 255, green 87, blue 51. Memory addresses: 0x7FFF = 32,767. Unicode: U+00E9 = é.

Hex is more compact than binary: the byte 11111111 (8 digits) = FF (2 digits). This is why hex is preferred for displaying binary data.

All calculations run locally in your browser — nothing is sent to any server.

How to use the converter?

  1. 1. Enter a value

    Type a number in the input field. You can use a period or comma as the decimal separator.
  2. 2. Read the result

    The conversion result appears instantly in the field next to it – no clicking required.
  3. 3. Copy or reverse

    Click Copy result or use the Reverse button to convert in the opposite direction.

When is this converter useful?

  1. CSS and HTML Color Codes

    Every CSS hex color is three hex pairs: #RRGGBB. #FF5733 = red 255, green 87, blue 51. Chrome DevTools shows colors in hex by default. Tailwind CSS v4 uses OKLCH, but legacy hex values remain common in codebases and design handoffs from Figma.
  2. JavaScript Hex Literals

    JavaScript accepts hex literals with the 0x prefix: 0xFF === 255, 0x1A === 26. The Number.toString(16) method converts to hex; parseInt('FF', 16) converts back. Chrome DevTools memory panel shows all addresses in hexadecimal.
  3. Network Packet Inspection

    Wireshark and tcpdump display packet contents as hex dumps. Each hex pair is one byte. MAC addresses use six hex pairs separated by colons: AA:BB:CC:DD:EE:FF. IPv6 addresses are eight groups of four hex digits.
  4. SHA and MD5 Hash Output

    Cryptographic hashes are always displayed in hexadecimal. An MD5 hash is 32 hex characters (128 bits). SHA-256 produces 64 hex characters (256 bits). Each hex character represents 4 bits, so two characters represent one byte.

What makes this converter different?

  1. Complete privacy

    All calculations run locally in your browser. No data is sent to any server.
  2. Real-time results

    The result updates instantly as you type – no need to click any button.
  3. Bidirectional conversion

    The Reverse button lets you convert in both directions with one click.
  4. Reference table

    A ready-made table with commonly converted values and contextual descriptions.

How does decimal to hex conversion work?

Repeatedly divide by 16 and record remainders (using A–F for 10–15). Read remainders bottom-to-top.

Example: 255 ÷ 16 = 15 R15 → F, 15 ÷ 16 = 0 R15 → F. Result: FF.

Each hex digit = 4 bits. Two hex digits = 1 byte (0–255). Four hex digits = 2 bytes (0–65,535).

Practical tips

  • Hex digits: 0123456789ABCDEF. A=10, B=11, C=12, D=13, E=14, F=15.
  • 1 byte: 00–FF (0–255). 2 bytes: 0000–FFFF (0–65,535).
  • Common prefixes: 0x (programming), # (CSS colors), U+ (Unicode).
  • MAC address: 6 bytes in hex, e.g. AA:BB:CC:DD:EE:FF.
ADVERTISEMENT

Decimal vs Hexadecimal

Decimal vs Hexadecimal
FeatureDecimal (base-10)Hexadecimal (base-16)
Digits0–90–9, A–F
Example: 255255FF
Example: 100010003E8
Used forEveryday mathColors, addresses, data
CompactnessStandardMore compact than binary

Decimal (base-10)

  • Digits
    0–9
  • Example: 255
    255
  • Example: 1000
    1000
  • Used for
    Everyday math
  • Compactness
    Standard

Hexadecimal (base-16)

  • Digits
    0–9, A–F
  • Example: 255
    FF
  • Example: 1000
    3E8
  • Used for
    Colors, addresses, data
  • Compactness
    More compact than binary

Convert Decimal to other units

DEC to BIN

Explore other unit converters

pt to pxrem to pxem to pxcm to pxmm to pxinches to pxDPI to PPIHEX to RGBRGB to HSLRGB to CMYKbytes to KB/MB/GBUnix to dateMbps to MB/svw to pxTailwind CSS spacing to px

Frequently asked questions

What is 255 in hex?

255 = FF in hexadecimal. This is the maximum value of one byte (8 bits). It appears in CSS as #FFFFFF (white), in RGB as rgb(255, 255, 255), and as 0xFF in C, JavaScript, and Python source code.

What is 0xFF in decimal?

0xFF = 255 in decimal. The 0x prefix signals hexadecimal in most programming languages. In JavaScript: 0xFF === 255 evaluates to true. In Python: hex(255) returns '0xff'. In C: printf("%d", 0xFF) prints 255.

How do CSS hex colors work?

#RRGGBB format uses two hex digits per channel. Each pair ranges from 00 (0) to FF (255). #FF0000 = red 255, green 0, blue 0. #1A2B3C = red 26, green 43, blue 60. Shorthand: #RGB expands to #RRGGBB — #F0A = #FF00AA.

What does 0x mean in code?

0x is a prefix signaling hexadecimal in C, C++, Java, JavaScript, Python, Go, and Rust. Example: 0x1A = 26 decimal. Python also accepts 0o for octal and 0b for binary. In CSS, # serves the same purpose for color values.

How do I read a memory address in Chrome DevTools?

Chrome DevTools Memory panel shows addresses like 0x7FFF5FBF. Convert: 0x7FFF = 32,767 decimal. Each hex character is 4 bits, so a 6-digit hex address represents a 24-bit value (up to 16,777,215). 64-bit addresses are 16 hex digits long.

What is a Unicode code point in hex?

Unicode code points are written as U+ followed by hex digits. U+0041 = decimal 65 = letter 'A'. U+00E9 = decimal 233 = 'é'. U+1F600 = decimal 128,512 = the grinning face emoji. JavaScript accesses them via String.fromCodePoint(65) or '\u0041'.

Why are SHA/MD5 hashes displayed in hex?

Cryptographic hash functions output raw bytes. Hex is the standard way to display binary data in a readable, copy-pasteable format. An MD5 hash is 16 bytes = 32 hex characters. SHA-256 is 32 bytes = 64 hex characters. Each pair of hex digits represents exactly one byte.

Are calculations done locally?

Yes. All calculations run in your browser. No data is sent to any server.

Decimal to hexadecimal converter – Arteon

Help us improve our tools

Have an idea, found a bug, or want to suggest a feature? Drop us a message – we respond within 24 hours.