Skip to content

How to deploy a mail server with BeAdmin ​

The BeAdmin panel lets you run your own mail server: create mailboxes on your own domains, set up forwarding aliases, and work with mail through the Roundcube web interface or mail clients over IMAP and SMTP. Exim sends and receives the mail, Dovecot stores it and gives access to the mailboxes, and the mailboxes and aliases themselves are kept in MariaDB.

This article describes a minimal scenario: install the module, create the first mailbox, add Roundcube, and connect a mail client. Working with the module itself is covered in Mail. Managing the module, and mailboxes, aliases, and domains in Mail. Mailboxes, aliases, and domains.

You'll need a server with BeAdmin — our partners ship a ready‑to‑use VPS the moment you order.

Proven over 15 years in hosting. Your VPS with BeAdmin is ready to go out of the box.

  • Germany
  • Netherlands
  • Sweden
  • Switzerland
  • Spain
  • USA
Select server

European reliability made simple. Launch BeAdmin with your VPS in just one click.

  • Germany
  • Netherlands
  • Sweden
  • Estonia
  • Romania
  • Switzerland
  • Spain
  • United Kingdom
  • USA
Sign up

What you need ​

  • A domain of your own. You can buy one from any registrar: your mailboxes will live on it. One domain is enough to start; any others connect to mail automatically when you create mailboxes on them.
  • Access to the domain's DNS. You need it to create an A record for the mail server address before the installation, and the MX, SPF, DKIM, and DMARC records after it.

Installing the module ​

Open "Mail" in the panel's side menu and click "Install". Mail needs MariaDB: it stores mailboxes, aliases, and account credentials. If MariaDB is not installed yet, install it first on the module page: the module's install button stays inactive until the dependency is installed.

The “Installation settings” dialog for the mail server: the “Primary domain” (example.com) and “Mail server address” (mail.example.com) fields, the collapsed “Extra settings” section, and the “Start installation” buttonThe “Installation settings” dialog for the mail server: the “Primary domain” (example.com) and “Mail server address” (mail.example.com) fields, the collapsed “Extra settings” section, and the “Start installation” button

In the installation parameters dialog, enter:

  • "Primary domain" — the domain for your mailboxes, for example example.com. It connects to mail right away and appears in "Websites & Domains" as a domain without a site, and a DKIM key is created for it.
  • "Mail server address" — the address mail clients use to connect to the server, for example mail.example.com. It must be the same as the primary domain or one of its subdomains. The panel requests an SSL certificate for this address from Let's Encrypt so that the connection between clients and the server is protected, so before installing, create an A record at your registrar pointing this address to the server's IP address. If there is no record, or it points to another server, the certificate cannot be issued and the server runs with a self-signed one: mail clients will warn about it.
  • "Dovecot database password" under "Extra settings" — the password of the MariaDB service user through which Dovecot works with the mailbox database. You do not need to change it: if you leave the field empty, the panel generates a password itself.

Click "Start installation". The installation takes a few minutes, and you can follow its progress in the log. When it finishes, the mailbox list opens.

A certificate failure does not stop the installation: the module is installed either way, and you can issue the certificate later. For how to do it, see Mail. Managing the module.

ℹ️ The mail server uses MariaDB

Do not remove the MariaDB module while mail is running: without the mailbox database, the server stops receiving and sending mail.

Your first mailbox ​

Create the first mailbox on the primary domain. The server generates the password and shows it only once, so save it right away. How to create a mailbox and what happens to the password is described in the Creating a mailbox section.

DNS records ​

The installation does not publish records in DNS, so you need to add MX, SPF, DKIM, and DMARC at your registrar. Without them, mail will not reach the mailboxes or will land in spam. Which records you need and how to check that they are published is described in the DNS records section, and the full set of records in How to configure DNS records for a mail server.

Installing the Roundcube web client ​

Roundcube is a web interface for mail: it lets you read and send messages right in the browser without setting up a mail client. Roundcube installs in one step and does not ask for any extra parameters:

  1. In the "Roundcube" block on the module page, click "Install". The installation takes a few minutes, and you can follow its progress with the "Log" button.
  2. When the installation finishes, click "Open": Roundcube opens in a new tab.
The “Mail server” page after installation: a Roundcube tile with an “Install” button, a “Mail domains” tile listing example.com and example.net with SPF, DKIM, and DMARC badges, the “Mailboxes” and “Aliases” tabs, and a list of four mailboxesThe “Mail server” page after installation: a Roundcube tile with an “Install” button, a “Mail domains” tile listing example.com and example.net with SPF, DKIM, and DMARC badges, the “Mailboxes” and “Aliases” tabs, and a list of four mailboxes

To sign in, enter the full mailbox address, for example info@example.com, and its password. Aliases cannot be used to sign in: they only forward messages. There is no single sign-on from the panel: you enter the mailbox address and password in Roundcube itself.

Roundcube runs on PHP, and a suitable PHP version may be missing on the server. In that case the block shows "Install PHP" instead of "Install": click it, wait for PHP to install, and then click "Install". You do not need to pick a version: the panel installs the newest suitable one. On older systems there may be no suitable PHP version at all: then Roundcube cannot be installed, but you can still use mail through mail clients.

Connecting an external mail client ​

You can connect a mailbox to any mail client over IMAP and SMTP — for example, Thunderbird, Apple Mail, Outlook, or Gmail on Android. The server settings and the guide for each client are in Mail. Connecting a mailbox to a mail client.

What's next ​

BeAdmin © 2025. All rights reserved.