Skip to main content
HexConverter

Text to Hex Converter

Encode plain text, ASCII strings, and multi-byte Unicode into hexadecimal byte representations. Inspect per-character code points, byte tables, and encodings (UTF-8, UTF-16, and Latin-1).

Try samples:
Encoding:
Format:
Hexadecimal Encoded Bytes (UTF-8)
Swap โ‡„
48 65 6C 6C 6F
Characters: 5โ€ขEncoded bytes: 5โ€ขAverage bytes/char: 1.00

Character-by-Character Byte Breakdown

Shows each character's Unicode code point and corresponding byte breakdown in UTF-8.

CharCode PointDecimal BytesHex BytesByte Count
HU+004872481 byte
eU+0065101651 byte
lU+006C1086C1 byte
lU+006C1086C1 byte
oU+006F1116F1 byte
Runs 100% in your browser. Nothing you enter is sent over the network.

Character Encodings and Byte Serialization

Every digital character begins as a Unicode code point (e.g. 'H' is U+0048). When written to memory, disk, or network packets, code points are serialized into bytes by an encoding algorithm:

  • UTF-8: Variable 1 to 4 bytes per character. 1 byte for English ASCII, 2 bytes for Latin/Greek/Cyrillic, 3 bytes for CJK/Euro, 4 bytes for Emojis.
  • UTF-16: Fixed 2 bytes for basic multilingual plane, 4 bytes for surrogate pairs.
  • ISO-8859-1 (Latin-1): Fixed 1 byte per character for Western European scripts. Characters beyond 255 cannot be encoded.

For a full character lookup of standard 7-bit characters, consult our Standard ASCII Table.

Verified Worked Examples

Example 1: ASCII Word "Hello"

Input:"Hello"
โ†’
Result:48 65 6C 6C 6F

5 characters, 5 bytes.

'H' = 72 (0x48)
'e' = 101 (0x65)
'l' = 108 (0x6C)
'l' = 108 (0x6C)
'o' = 111 (0x6F)

Example 2: Accented "รฉ" (2 Bytes UTF-8)

Input:"รฉ"
โ†’
Result:C3 A9 (UTF-8) vs E9 (Latin-1)

Demonstrates multi-byte expansion in UTF-8.

Unicode Code Point: U+00E9
UTF-8 binary: 11000011 10101001
Hex: C3 A9

Example 3: Currency Symbol "โ‚ฌ" (3 Bytes)

Input:"โ‚ฌ"
โ†’
Result:E2 82 AC

Euro currency sign requires 3 bytes in UTF-8.

Unicode Code Point: U+20AC
UTF-8 binary: 11100010 10000010 10101100
Hex: E2 82 AC

Example 4: Emoji "๐Ÿ˜€" (4 Bytes)

Input:"๐Ÿ˜€"
โ†’
Result:F0 9F 98 80

Supplementary plane character.

Unicode Code Point: U+1F600
UTF-8 binary: 11110000 10011111 10011000 10000000
Hex: F0 9F 98 80

Frequently Asked Questions

Direct answers to technical and practical questions regarding this tool and base-16 conversion.

How does text convert into hexadecimal?

Computers do not store letters directly; they store numeric code points according to character encodings like ASCII or Unicode. In UTF-8, each character is transformed into a sequence of 1 to 4 bytes (8-bit numbers). Each byte is then written as two hexadecimal digits. For example, ASCII letter "H" has code point 72, which is 0x48 in hexadecimal.

Why does the accented character "รฉ" produce two hex bytes in UTF-8 but only one in Latin-1?

Standard ASCII only covers English letters from 0 to 127 (1 byte). To support global alphabets and symbols while remaining backward-compatible with ASCII, UTF-8 uses variable-length encoding: characters from 128 to 2047 require 2 bytes. The character "รฉ" (U+00E9) is encoded as two bytes in UTF-8: 0xC3 and 0xA9. In ISO-8859-1 (Latin-1), however, "รฉ" fits in a single 8-bit byte as 0xE9.

Why do emojis like ๐Ÿ˜€ require 4 bytes (8 hex digits)?

Emojis have high Unicode code points above U+FFFF (in Unicode supplementary planes). In UTF-8, characters in the range U+10000 to U+10FFFF require 4 bytes. The grinning emoji ๐Ÿ˜€ (U+1F600) encodes to four consecutive bytes: 0xF0 0x9F 0x98 0x80.

What is the difference between ASCII and UTF-8?

ASCII is a 7-bit character set defining 128 characters (English alphabet, numbers, punctuation, and control codes). UTF-8 is a modern, variable-length universal encoding capable of representing all 1,114,112 Unicode code points across every human language. ASCII is a strict subset of UTF-8: any valid ASCII file is identically valid in UTF-8.

What delimiter should I use when converting text to hex for programming?

It depends on your language. In C/C++ and Python string literals, use "\x" (e.g. "\x48\x65"). In byte arrays or memory dumps, space-separated or comma-separated "0x" (e.g. "0x48, 0x65") is standard. For URL query strings, percent signs are used ("%48%65").

Related Conversion Tools & Resources

Explore companion converters, bitwise arithmetic calculators, and reference charts.

Sources & Technical References

Technical Verification & Editorial Accountability

Written by Sarah Chen (Embedded Systems Engineer) โ€ข Verified by Marcus Brody, PE

Reviewed: 2026-10-02MethodologyEditorial PolicyReport Error