How to Download and Install Htpasswd in Debian, Ubuntu Latest Version, Alpine, Arch, Kali Distro, CentOS, Fedora & Raspbian From Terminal
htpasswd
Maintainer: Debian Apache Maintainers
Email: [email protected] .
Website: https://httpd.apache.org/
Section: httpd
Install htpasswd
-
Debian
apt-get install apache2-utilsClick to copy -
Ubuntu
apt-get install apache2-utilsClick to copy -
Alpine OS
apk add apache2-utilsClick to copy -
Arch Linux
pacman -S apacheClick to copy -
Kali Linux
apt-get install apache2-utilsClick to copy -
CentOS
yum install httpd-toolsClick to copy -
Fedora
dnf install httpd-toolsClick to copy -
Raspbian
apt-get install apache2-utilsClick to copy
Create and manage htpasswd files to protect web server directories using basic authentication.
How to use htpasswd?
Below are few example commands for htpasswd that you can use in the terminal.
Create/overwrite htpasswd file:htpasswd -c path/to/file user_nameClick to copyAdd user to htpasswd file or update existing user:htpasswd path/to/file user_nameClick to copyAdd user to htpasswd file in batch mode without an interactive password prompt (for script usage):htpasswd -b path/to/file user_name passwordClick to copyDelete user from htpasswd file:htpasswd -D path/to/file user_nameClick to copyVerify user password:htpasswd -v path/to/file user_nameClick to copy
Htpassowrd is the best linux utility to manage our passwords and directories. In order to To download the latest version of htpasswd in your favorite operating system just copy the htpasswd installation command from above and paste it into terminal. It will download the latest version of htpasswd 2026 from the repo and that would be the updated one that is what exactly you need to manage your directories and passwords.




