Repository navigation
Installing hMailServer
This page began as a chapter of the 6.2.10 manual and has been corrected for 6.2.24. The Control Panel's pages are grouped differently now, so the paths below use today's groups; the TLS ports 465, 993 and 995 exist only after you create them on the TCP/IP ports page (a fresh install seeds 25, 587, 110 and 143); and everything added since 6.2.10 is in Changes Since 6.2.10. Where a value here disagrees with the Settings Reference, which is generated from the code, the reference is right.
Get hMailServer-6.2.27-x64.exe from the
releases page.
Each release also carries SBOM files (hmailserver.spdx.json,
hmailserver.cyclonedx.json) — a full inventory of every component in the build, for
anyone who needs to audit their supply chain. You do not need them to install.
Right-click the installer and choose Run as administrator.
Work through the wizard:
1. Licence agreement. hMailServer is AGPL-3.0. In short: you may use it freely, including commercially; if you modify it and offer it to others over a network, you must publish your changes.
2. Destination folder. The default C:\Program Files\hMailServer is fine.
3. Components. This page matters, so read it:
| Component | Take it? | What it does |
|---|---|---|
| Server | Yes | The mail server itself. Everything else is optional. |
| Control Panel | Yes | The administration application. Without it you have no GUI. |
| Remote administration support | Only if scripting from another machine | Registers the COM API so scripts on a different machine can administer this server. The Control Panel does not need it — it connects to remote servers by itself. |
Note for upgraders: "Administrative tools" in older versions bundled the classic Administrator and a PHP web interface. Both are gone (see chapter 25). The component now does only what it always really did — register the COM type library for scripts.
4. Database type. Choose Use built-in database server (Microsoft SQL Compact) unless you decided otherwise in §3.5.
5. Administrator password. hMailServer asks you to set a password for the administration interface. This is not an email password — it is the master password for the whole server.
Use a long, unique password and store it in a password manager. Anyone with it owns every mailbox on the server.
6. Install. The installer copies files, creates the database, registers the hMailServer Windows service and starts it. If the .NET 10 Desktop Runtime is missing it is installed silently — this is what the Control Panel needs to run.
Open Services (services.msc) and find hMailServer. It should say Running,
startup type Automatic.
Or from PowerShell:
Get-Service hMailServerStatus Name DisplayName
------ ---- -----------
Running hMailServer hMailServer
The installer does not open firewall ports for you. Until you do, nothing can reach your server. Run this in an elevated PowerShell:
New-NetFirewallRule -DisplayName "hMailServer SMTP" -Direction Inbound -Protocol TCP -LocalPort 25 -Action Allow
New-NetFirewallRule -DisplayName "hMailServer Submission" -Direction Inbound -Protocol TCP -LocalPort 587 -Action Allow
New-NetFirewallRule -DisplayName "hMailServer IMAP" -Direction Inbound -Protocol TCP -LocalPort 143 -Action Allow
New-NetFirewallRule -DisplayName "hMailServer IMAPS" -Direction Inbound -Protocol TCP -LocalPort 993 -Action Allow
New-NetFirewallRule -DisplayName "hMailServer POP3" -Direction Inbound -Protocol TCP -LocalPort 110 -Action Allow
New-NetFirewallRule -DisplayName "hMailServer POP3S" -Direction Inbound -Protocol TCP -LocalPort 995 -Action AllowYour router or cloud firewall needs the same ports forwarded to this machine.
The installer is Inno Setup, so the standard switches apply: /SILENT or /VERYSILENT,
/SUPPRESSMSGBOXES, /LOG="<path>", /DIR="<path>" and
/COMPONENTS="server,admintools,controlpanel". Two switches are this installer's own:
/useinternaldbms=true|false (true, the default, uses the bundled SQL Server Compact
database; false when pointing at an existing MySQL, MariaDB, PostgreSQL or MS SQL server)
and /adminpassword=<password>, which sets the administrator password the wizard page
would have asked for (at least five characters). Without it the password is left unset,
and the REST API refuses to start until one is set.
hMailServer-6.2.27-x64.exe /VERYSILENT /SUPPRESSMSGBOXES /LOG="C:\Temp\hmail-install.log" ^
/COMPONENTS="server,controlpanel" /useinternaldbms=true /adminpassword=<password>The installer checks that the database tool ran and its exit code, so a failed database
create or upgrade cannot report a successful install. Use /LOG; it is the only record of
what happened.
hMailServer 6.3.8, the latest release (2 November 2026, schema 6108) · AGPL-3.0-or-later · Repository · Mirror on GitHub · Report a documentation error (a GitLab issue naming the page)
Home — full index
Start here
1. Install and run
- Before You Install
- Installing hMailServer
- Installing on Linux
- Running in a Container
- Profiles and Environment
- The Control Panel
- The Control Deck
- Your First Domain and Mailbox
- Connecting a Mail Client
- The Webmail
- DNS for Your Domain
- Migration
2. Secure it
- Encryption and Certificates
- Database TLS
- Encryption for People
- Stopping Spam
- Stopping Viruses
- Security Hardening
- Secure Defaults
- The Service Account
- Secrets at Rest
- Sign-in and Identity
- Security Policy
3. Operate it
- Monitoring and Health
- The SNMP Agent
- Backup and Restore
- Message Storage
- Compliance and eDiscovery
- Troubleshooting
- Diagnosing Stalled Mail
- Relocating an Installation
- Upgrading hMailServer
- Upgrading Guide
- The Update Feed
- Migrating the Database Backend
- High Availability Runbook
- Warm Standby
- Runbooks Digest
4. Extend it
- Rules and Sieve
- Aliases Lists and Public Folders
- Rooms and Equipment
- Mailing Lists
- Routes and Relays
- Mail In to a Webhook
- Outbound Shaping
- The COM API and Scripting
- Event Scripts
- The REST API
- Command Line
- APIs Reference
5. Contribute to it
- Project Handbook
- Architecture
- Contributing
- Release Process
- Governance
- Assurance Case
- Regression Test Environment
- Fuzzing
- Regulatory Scope
- Third-Party Binaries
Look it up — from any journey
- Settings Reference
- Settings Overview
- Capabilities and Configuration
- Control Panel Reference
- Control Panel Pages
- Ports Reference
- Changes-Since-6210
- Version-History-to-6210
- Glossary
About this wiki
- hMailServer 6.3.8 is the latest release (2 November 2026, schema 6108)
- Pages say since 6.3.4 where a feature is new in it
- AGPL-3.0-or-later
- Repository, the one place the project is worked on
- Its mirror on GitHub, since 18 October 2026, with no Issues
- Questions: a GitLab issue with the Question template, GitHub Discussions Q&A, or the forum
- Report a documentation error: a GitLab issue naming the page