Random Generators100% Client-Side

Generate Random Bytes

Choose a byte length and a text representation for the result. The generator can return a continuous hexadecimal string, a Base64 string, or a comma-separated list of byte values. The byte count describes the underlying data and can differ from the number of visible characters. This is useful when testing decoders or preparing fixtures for an interface that accepts one particular byte encoding. Compare the decoded byte count with your setting when checking the result in another tool.

Configuration Options
Output

How to Use the Random Byte Generator with Three Formats

  1. 1Set Byte Length to the size in bytes.
  2. 2Choose Output Format as hexadecimal, Base64, or decimal.
  3. 3Use Generate and check the format expected by the receiving tool.
  4. 4Save the exact output if you need to decode or reproduce that fixture later.

Input & Output Examples

One possible result. The Base64 string represents four underlying bytes.

Input Sample
Four bytes in Base64
Expected Output
AQIDBA==

One possible result. Each written number represents one byte.

Input Sample
Three bytes in decimal notation
Expected Output
0, 128, 255

Practical Developer Workflows

  • Create binary test data represented in the encoding an import field supports.
  • Check how encoded length changes when a fixture contains one more byte.
  • Generate a short decimal byte list for comparing individual values in a parser test.

Zero Server Uploads & Complete Privacy

Runs 100% in your browser; no data is uploaded to any server.

Notice a bug, calculation error, or outdated info?

Let us know directly so our engineering team can fix it.

Frequently Asked Questions

Hexadecimal uses two digits per byte. The output has no spaces, and any necessary leading zero is included in each byte's pair. For example, requesting four bytes produces eight hexadecimal digits.

Explore Other Tools

12 suggested tools

View all tools