After installation you log in to Mailcow at https://mail.your-domain.com/admin with the user admin and the password moohoo. Change the password right after your first login. If you forgot your admin password, reset it over SSH with a script that ships with Mailcow:
cd /opt/mailcow-dockerized
./helper-scripts/mailcow-reset-admin.sh Login fails although the password is right?
In current Mailcow versions the admin login is at /admin. The start page only accepts mailbox logins. If you enter the admin credentials there, you won’t get in.
Reset the admin password
- Log in to the server as root via SSH.
- Change to the Mailcow directory. The default is
/opt/mailcow-dockerized. If you don’t remember where Mailcow lives,docker compose lsshows the path to its configuration. - Run
./helper-scripts/mailcow-reset-admin.shand confirm the prompt withyes.
The script then shows you a new random password:
Checking MySQL service... OK
Are you sure you want to reset the mailcow administrator account? [y/N] yes
Working, please wait...
Reset credentials:
---
Username: admin
Password: T2Kj9TtM1ZhngAWD
TFA: none Use these credentials to log in at /admin and set your own password right away. ?TFA: none? means that two-factor authentication for the admin has been reset as well. Set it up again if you need it.
What the script doesn’t change
The script only resets the administrator. Mailbox passwords for SOGo, IMAP and SMTP stay as they are. You change those as admin in the Mailcow interface for each mailbox.