Xxd Command Not Found | 2026 Edition |
Below are the installation instructions for Linux, macOS, Windows (via WSL or Git Bash), and *BSD systems.
You will see this error under three main scenarios: xxd command not found
Before diving into the fix, let’s understand the tool. xxd is a command-line utility that creates a hexadecimal dump of a given file or standard input. It can also do the reverse: convert a hexadecimal dump back into binary form. Below are the installation instructions for Linux, macOS,
xxd is not a standalone package on most systems. Instead, it is bundled with Vim (Vi IMproved). When you install Vim, xxd is compiled and installed alongside it as a helper utility. This is the primary reason why xxd is missing from many minimal installations—they may include vi (or nano), but not the full vim package. It can also do the reverse: convert a
When writing scripts that rely on xxd, always check for its presence:
#!/bin/bash
if ! command -v xxd &> /dev/null; then
echo "Error: xxd is not installed. Please install vim or xxd package."
exit 1
fi
After installing, test with:
xxd --version