Tools
EN

Base64 to Hex Converter

Convert Base64 strings to hexadecimal bytes and back. Useful for inspecting binary data, hashes, keys, UUIDs and network payloads.

Private: your data is processed in your browser and never uploaded.

How to convert Base64 to hex

  1. Choose the direction: Base64 → Hex or Hex → Base64.
  2. Paste your input. Hex input may contain spaces, colons, 0x or \x prefixes.
  3. Pick the letter case and byte separator, then copy the result.

Base64 vs hexadecimal

Both encodings represent binary data as text. Hexadecimal uses 2 characters per byte (100% overhead) and is easy to read byte by byte, which is why hashes and keys are often shown in hex. Base64 uses 4 characters per 3 bytes (33% overhead) and is more compact for transport.

TextBase64Hex
HiSGk=48 69
HelloSGVsbG8=48 65 6c 6c 6f

Frequently asked questions

How do I convert a SHA-256 hash from Base64 to hex?

Paste the Base64 hash (44 characters ending in =) and you get 64 hexadecimal characters, the format used by most command-line tools.

Can hex input contain spaces or 0x prefixes?

Yes. Spaces, line breaks, colons, dashes and 0x or \x prefixes are removed automatically before conversion.

Why must hex have an even number of digits?

Each byte is written as exactly two hex digits. An odd count means a digit is missing, usually a leading zero.