Updated: 28 September 2026 · Applies to: Webmin 2.670
Webmin can manage everything on your server, so it is a favourite target for attackers. Two simple measures make it much safer: move it away from the well-known port 10000, and allow only your own IP addresses to connect. Both are set in Webmin's own configuration module.
Change the port
- Log in to Webmin.
- Open Webmin › Webmin Configuration and click Ports and Addresses.
- In Listen on port enter the new port number, for example
12345. Choose a number between 1024 and 65535 that no other service uses. - Click Save. Your browser is sent to the new port; if it does not follow, open
https://YOUR-SERVER-IP:12345yourself. - Open the new port in the firewall and close the old one:
# Ubuntu / Debian with ufw sudo ufw allow 12345/tcp sudo ufw delete allow 10000/tcp # AlmaLinux / Rocky / RHEL with firewalld sudo firewall-cmd --permanent --add-port=12345/tcp sudo firewall-cmd --permanent --remove-port=10000/tcp sudo firewall-cmd --reload
Do the firewall change before or right after you save; if you saved first and the port is blocked, the page will not open. To undo it from the server, edit /etc/webmin/miniserv.conf, set port=10000 and run sudo systemctl restart webmin.
Allow only your own IP addresses
- Find your public IP address, for example by opening
curl https://ifconfig.meon your computer or by asking your provider. If your address changes often, use a network range or a VPN with a fixed address. - In Webmin open Webmin › Webmin Configuration › IP Access Control.
- Select Only allow from listed addresses.
- Enter your address (or a network such as
192.168.1.0/255.255.255.0), one per line. Hostnames are also accepted. - Click Save.
By default Webmin accepts connections from any address and relies on the password alone. After this change, anyone else gets a refusal before they can even try a password. Make sure the list contains the address you use right now, or you lock yourself out. If that happens, remove the line starting with allow= in /etc/webmin/miniserv.conf from an SSH session and restart Webmin (sudo systemctl restart webmin).
Even better: block the port and use an SSH tunnel
Keep port 10000 closed in the firewall and connect through SSH when you need Webmin:
ssh -L 10000:127.0.0.1:10000 user@YOUR-SERVER-IP
Then open https://127.0.0.1:10000. For this to work, Webmin must accept connections from the server itself, which is the default.
More protection
- Use a long, unique password and two-factor authentication (Webmin › Webmin Configuration).
- Install a real certificate: How to secure Webmin with a Let's Encrypt SSL certificate?.
- Keep Webmin updated: How to update or uninstall Webmin?.
Frequently asked questions
Is changing the port real security?
It reduces automatic scans, but it does not replace a firewall or a strong password. Use it together with IP access control.
I cannot reach Webmin after changing the port.
The firewall does not allow the new port. See How to fix Webmin not opening on port 10000?.
Official documentation: Webmin documentation: Webmin Configuration.
Need a server for Webmin, or a hand with the setup?
- Managed Webmin VPS: a KVM VPS with Webmin where updates, security and monitoring are handled for you.
- KVM VPS with NVMe storage: full root access, so you can install and manage Webmin yourself.
Prefer a hand with the setup? Our engineers can do it for you: Hire an Expert, or use our on-demand server management.
