Preparing for system design interviews?  Try bugzed.com →

HexBytes: Python `bytes` subclass for hex representation

JSON →
library 1.3.1 ·python
verified Jun 28, 2026 install

HexBytes is a thin wrapper around the Python built-in `bytes` class (version 1.3.1). It extends `bytes` by accepting a wider range of initialization types including `bool`, `int`, `str`, `bytearray`, and `memoryview`. Key features include a 0x-prefixed console representation (`__repr__`) and a `to_0x_hex()` method for consistent 0x-prefixed hexadecimal string output. The library is actively maintained with regular releases.

total hits 12
actors 4 distinct systems
last hit 9d ago AhrefsBot
GPTBot
4
Amazonbot
4
Script
1

top countries 🇺🇸 United States · 🇬🇧 United Kingdom · 🇫🇷 France · 🇩🇪 Germany