Text To Hex Converter
Base32, Base58, Base85 And Bytes
This tool will convert text into several formats including hex, base 32, base 58, base 85, decimal bytes, octal bytes, code points and utf-16 units. The tool also converts all these formats back into text. All of this is done directly within your web browser. No data is sent over the internet.
- FreePrice
- 8Formats
- NoneSign-up
- NoneUploads
Text To Hex Converter
Turn text into hex, Base32, Base58, Base85, bytes or code points
- Characters
- 0
- UTF-8 bytes
- 0
- Encoded length
- 0
Ready. Type some text to encode it.
What A Text To Hex Converter Does For You
Computer’s store text using numbers. The number used for every character is called its code. It can take either one byte or several bytes to store that code. You will often need to view those bytes.
The Hex Converter will show you the results of converting your text into hex format. Start by typing or pasting your text into the first field. Second, select the format you would like to use for your output. The output will be displayed right away. You can now copy the resulting bytes with a simple click.
The program can turn text into hexadecimal and turn hexadecimal into text. You can copy-paste hex, base32 or an array of bytes, and the software will convert it into readable text. This allows you to view data that has been dumped from a log file, network packet, or database.
All of the work is done within your own web browser, so the text you translate into Hex does not leave your personal computer.
How Text Becomes Bytes
To a computer, text is just a string of characters. First, the computer converts each character into a numerical value and then into bytes. This conversion can be done using several different methods; but UTF-8 is probably the most commonly used method. With UTF-8, each letter in English takes up one byte, and most letters with accents take up two bytes.
So the word Hi becomes the bytes 72 and 105, which is 48 69 in hex.
For full details, see RFC 4648, the Base16, Base32 and Base64 encodings.
Text To Hex
Hex writes each byte as two digits from 0 to 9 and a to f. Pick a separator, add a 0x before each byte if you like, and choose capital letters. Then copy the result.

For example, Hello comes out as 48 65 6c 6c 6f.
Hex To Text
First, switch the direction to Code to text and paste your hex. The tool ignores spaces, commas, colons and prefixes such as 0x. Then it joins the digits in pairs and reads the bytes as UTF-8.
Base32
Base32 uses 32 safe characters: the capital letters A to Z and the digits 2 to 7. It follows the standard in RFC 4648. People use it for one time password keys and for names that must not depend on case.
Also, the tool adds equals signs as padding, unless you turn them off.
Base58
Base58 drops the look alike characters 0, O, I and l. That makes it simpler to read and type. Also, bitcoin addresses and many short ids use it. Zero bytes at the start turn into leading ones.
Base85
Base85, also called Ascii85, packs four bytes into five characters. So it’s shorter than Base64. PDF and PostScript files use it.
The first step is to convert each four zero-byte segment into one single "z" character. The final result may then be wrapped in the Adobe mark.
Decimal And Octal Bytes
Each byte can be represented in three ways; first as a decimal value (from 0 to 255), second as an octal value (from 000 to 377). As a result, Hi! becomes 72 105 33 in decimal representation. So, use these values to represent items in a look up table or in ancient communications protocols.
Unicode Code Points
A code point is the number assigned by Unicode to each character. The software then displays this code point as "U+0041". In addition to displaying the code point, the software gives the escape sequence used in JavaScript.
In other words, the smiling face is a single code point (U+1F600) yet needs four bytes when encoded in UTF-8.
UTF-16 Code Units
JavaScript and Windows represent text using UTF-16 code units (16-bit numbers). Every unit stands for one character. An emoji needs two units, referred to as a "surrogate pair." This tool displays these units as hexadecimal values, allowing you to view the surrogate pair.
Characters Versus Bytes
Three numbers are listed in the stats. The number of characters is equal to what is displayed on the screen. The number of UTF-8 bytes represents the amount of data stored. The number of encoded lengths represents the number of characters that will ultimately be generated. So, a small emoji-based text can contain more bytes than characters.
Invalid Input
If the text holds a wrong character, the tool says so. An odd number of hex digits also gives an error, because a byte needs two.
Even with invalid UTF-8 bytes, the program can read the text and then alert you to the presence of replacement characters.
Common Uses
Developers use hex to read network data, check file headers, debug encodings and write test data. Also, Base32 and Base58 show up in keys and ids. So one tool saves a lot of switching.
Safe By Design
First, the checker operates directly within your web browser. No data is sent from the browser, and no data remains after you exit the page. So, the converted text will remain yours only.
On this page
- The tool
- What A Text To Hex Converter Does For You
- Text To Hex In A Few Quick Steps
- What Makes This Text To Hex Converter Different
- Habits For Working With Encoded Text
- Common Encoding Mistakes This Tool Helps You Avoid
- Questions People Ask About Text To Hex
- Handy Companions For Encoding Work
Keep going
Using the Text to Hex Converter: A Short Video Guide
This brief video shows each step from start to finish. Choose your language below, and switch on captions if they help.
Text To Hex In A Few Quick Steps
Four steps take you from text to bytes.
Pick a direction
Pick Text to code or Code to text.
Pick a format
Choose hex, Base32, Base58, Base85, bytes or code points.
Type or paste
The result builds up as you type.
Copy or save
Copy the result, save it as a file, or swap the sides to double-check it.
What Makes This Text To Hex Converter Different
It knows eight formats, it speaks UTF-8, and it keeps your text private.
Eight formats
Hex, Base32, Base58, Base85, decimal, octal, code points and UTF-16.
Both directions
Encode text and decode it again with the same settings.
True UTF-8
Accents, symbols and emoji turn into the right bytes.
Tidy options
Pick the separator, the case, the prefix and the padding.
Byte counts
See the characters, the UTF-8 bytes and the encoded length.
Nothing leaves your tab
The conversion of text is done on your end by using your own browser. At Denwix, no one will see the text that you have converted.
Habits For Working With Encoded Text
A few habits keep your bytes honest.
- Know the encoding. Hex of UTF-8 differs from hex of UTF-16, so name the one you use.
- Keep the separator steady. Use one separator through a whole file.
- Match the case. Hex is case free, but Base58 is not. Copy the hex just as it stands.
- Mind the padding. Some Base32 readers need the equals signs, and some do not.
- Check the round trip. Use Swap sides to be sure the text comes back unchanged.
- Watch accents. In UTF-8, an accented letter needs two bytes.
- This is not encryption, so do not call it that. Encoding hides nothing. Anyone can decode it.
- Mind whitespace. A stray space or line break changes the bytes.
- Test with a sample. Try the sample before you trust a long input.
- Keep secrets out. Do not paste live keys into any online tool.
- Save long output. Download a file instead of copying thousands of bytes.
Common Encoding Mistakes This Tool Helps You Avoid
Each of these quietly garbles text.
Mixing up encodings
UTF-8 bytes read as another encoding show odd symbols.
Odd digit counts
A byte needs two hex digits, so an odd count means a lost digit.
Lost padding
A Base32 string cut short no longer decodes.
Look alike letters
Base58 has no 0, O, I or l, so such letters signal a typo.
Counting characters as bytes
An emoji counts as one character but uses four bytes.
Treating encoding as a lock
Hex and Base32 only change the form of the data.
Questions People Ask About Text To Hex
Does this text to hex converter cost anything?
Yes. You pay nothing, you need no account, and there’s no cap. Your browser does the heavy lifting, so we have no server bill to recover from you.
Does the text I convert to hex ever leave my computer?
No, the browser converts it. It does not send it to our website, and we do not store anything.
How can I turn text into hex?
Choose Text to code and Hex, and then enter or paste your text. Your hex bytes will be displayed as you type.
How can I turn hex back into text?
Switch the mode to Code to Text, choose HEX from the options and then enter your HEX. The tool will decode the bytes into UTF-8 and display the text.
What is hex?
It is base sixteen. It writes each byte as two digits from 0 to 9 and a to f, so 255 becomes ff.
What is UTF-8?
This is how most text files are converted to byte streams. It will use one byte for each letter of the alphabet in English, and can use as many as four bytes per character for non-English letters.
Why does a letter like é give two bytes?
In UTF-8, accented letters need two bytes each. So é becomes c3 a9 in hex.
Can I choose a different separator between the bytes?
Yes. In the Separator box, choose a space, nothing, a comma or a new line.
How do I add 0x before each byte?
Select Add "0x" before each byte. Select a comma for the delimiter to create a list of bytes that can be used in your code.
Can the output use capital letters?
Yes. Tick Capital letters for hex or UTF-16, and the digits a to f become A to F.
What is Base32?
A way to write bytes with 32 characters: A to Z and 2 to 7. It is common in one time password keys.
What is Base58?
Like Base64, but without the look alike characters 0, O, I and l, and without plus and slash. Bitcoin addresses use it.
What is Base85?
Also called Ascii85. It packs four bytes into five characters, so it is shorter than Base64.
Why does Base32 end with equals signs?
They pad the text to a multiple of eight characters. Untick Pad with equals signs to drop them.
What are decimal and octal bytes?
The same bytes written as numbers from 0 to 255 in decimal, or from 000 to 377 in octal.
What is a Unicode code point, and how do you write one?
It is the number Unicode gives to each character, usually written like U+0041. The tool also offers an escape style.
What exactly are UTF-16 code units?
They are the 16 bit numbers that JavaScript and Windows use to store text. An emoji uses two of them.
How many bytes does one emoji use?
Four in UTF-8, and two code units in UTF-16.
Why does it say the length is odd?
Hex needs two digits for each byte, so an odd count means a digit is missing. UTF-16 needs four digits per unit.
What happens if the bytes are not valid UTF-8?
The tool keeps showing the text. It marks the broken bytes with the replacement sign and warns you.
Is hex or Base32 a form of encryption?
No. They only change how the data is written. Anyone can decode them.
What does the Swap sides button do?
It moves the result to the left box and flips the direction, so you can test a round trip.
Does it run on phones too, or only on desktops?
Yes. The panels stack and the boxes scroll. That lets you convert text wherever you are.
Handy Companions For Encoding Work
Converting is one step. These three tools help with the rest.
- Base64 Encoder
Encode text and files in Base64, or decode them.
- Binary Translator
Turn text into ones and zeros, and back again.
- HTML Entity Encoder
Turn characters into named or numeric HTML entities, or back.
Want To Convert Some Text Now?
Type your text, choose a format, then copy what comes out. The converter is free, needs no account, and keeps every character on your device.