GoAdmio
GoAdmio Documentation

Custom SMTP Relay

From the GoAdmio knowledge base.

Custom SMTP Relay

This page explains the Custom SMTP Relay feature in GoAdmio. It lets you route outgoing email from every domain on the server through a third-party SMTP relay — such as Brevo, SendGrid, AhaSend, Mailgun, Amazon SES, or any SMTP-compatible provider.

Location: Admin Panel → Email → Custom SMTP Relay



Overview

By default, GoAdmio sends outgoing email directly through Postfix (port 25). Many hosting providers block port 25 to fight spam, which causes email to fail or land in spam folders. A Custom SMTP Relay solves this by forwarding all outgoing mail through a trusted third-party SMTP service that is authorized to send on your behalf.

When you configure a Custom SMTP Relay, every domain and every email account on the server uses it automatically — no per-domain configuration is needed. This is ideal for resellers and hosters who want consistent deliverability across all their customers.

> Note: This is different from Global SMTP Relay, which sets a relay for the server administrator, and Roundcube Global/Custom SMTP, which configure the webmail client only. The Custom SMTP Relay applies to all outgoing mail from every domain.



Why Use an SMTP Relay

| Problem | How a relay helps |
|---|---|
| Port 25 blocked by hosting provider | Relay sends over port 587 or 465, which is never blocked |
| Email lands in spam | Relays have established sender reputation and handle SPF/DKIM/DMARC correctly |
| IP blacklisted | Relay uses its own IPs, avoiding your server's reputation issues |
| No reverse DNS (PTR) | Relay handles PTR and authentication |
| Large email volume | Relays are built for high throughput and have rate limits documented upfront |
| Compliance | Some relays provide audit logs, suppression lists, and unsubscribe management |

> Tip: For shared hosting with many customers, an SMTP relay is often the single biggest improvement to email deliverability.



Supported Providers

GoAdmio's Custom SMTP Relay works with any SMTP server that supports standard authentication. Common providers:

| Provider | Free Tier | Ports | Notes |
|---|---|---|---|
| Brevo (formerly Sendinblue) | 300 emails/day | 587, 465 | GoAdmio has dedicated Brevo API integration — see Brevo API |
| SendGrid | 100 emails/day | 587, 465, 25 | Widely used, reliable reputation |
| AhaSend | Varies | 587, 465 | Modern transactional email service |
| Mailgun | Trial | 587, 465 | Good for developers, strong API |
| Amazon SES | Pay-as-you-go | 587, 465 | Very cheap at scale, requires domain verification |
| Postmark | Trial | 587, 465 | Excellent for transactional mail |
| SparkPost | Trial | 587, 465 | High volume, strong analytics |
| Mailjet | 200 emails/day | 587, 465 | Simple setup |
| Any SMTP server | — | Any | Custom relay credentials |

> Note: Each provider requires you to verify your sending domain and obtain SMTP credentials (host, port, username, password). Some also require you to add SPF/DKIM records. See your provider's documentation.



Prerequisites

Before configuring a Custom SMTP Relay:

  1. Provider account created and the domain(s) verified. See the provider's onboarding steps.
  2. SMTP credentials — host, port, username, and password (or API key) from the provider.
  3. Domain authentication records — SPF, DKIM, and (optionally) DMARC records from the provider added to your DNS. See SPF / DKIM and DNS Manager.
  4. Firewall — outbound port 587 (or 465) must be open. Port 25 does not need to be open when using a relay.
  5. Root access to the GoAdmio Admin Panel.
> Tip: Test the relay credentials with a mail client (e.g., Thunderbird) before configuring GoAdmio. A successful test in a mail client confirms the credentials and network path work.

How to Configure a Custom SMTP Relay

  1. Log in to the GoAdmio Admin Panel.
  2. Navigate to Email → Custom SMTP Relay.
  3. Click Add Relay (or Configure Relay).
  4. Enter the relay details:
| Field | Description | Example | |---|---|---| | Relay Host | The SMTP server hostname or IP | smtp-relay.brevo.com | | Port | SMTP port (587 for STARTTLS, 465 for SSL/TLS) | 587 | | Encryption | STARTTLS, SSL/TLS, or None | STARTTLS | | Username | SMTP username (often your provider account email) | your-account@example.com | | Password | SMTP password or API key | xsmtpsib-... | | From Address | The envelope sender address | noreply@example.com | | From Name | Display name for outgoing mail | Example Hosting | | Require Authentication | Whether the relay requires AUTH | Yes | | Enable for All Domains | Apply the relay server-wide | Yes |
  1. Click Save.
The relay is applied to Postfix immediately. Outgoing mail from every domain on the server now routes through the relay.

Provider-Specific Examples

Brevo

| Field | Value |
|---|---|
| Relay Host | smtp-relay.brevo.com |
| Port | 587 |
| Encryption | STARTTLS |
| Username | Your Brevo account email |
| Password | Your Brevo SMTP key (not your login password) |

> Tip: GoAdmio also has a dedicated Brevo API integration — see Brevo API for per-domain configuration.

SendGrid

| Field | Value |
|---|---|
| Relay Host | smtp.sendgrid.net |
| Port | 587 |
| Encryption | STARTTLS |
| Username | apikey (literally the word "apikey") |
| Password | Your SendGrid API key |

> Note: SendGrid uses the literal string apikey as the username. Use your API key as the password.

AhaSend

| Field | Value |
|---|---|
| Relay Host | smtp.ahasend.com |
| Port | 587 |
| Encryption | STARTTLS |
| Username | Your AhaSend SMTP username |
| Password | Your AhaSend SMTP password |

> Tip: Check AhaSend's dashboard for the exact SMTP hostname and credentials for your account.

Amazon SES

| Field | Value |
|---|---|
| Relay Host | email-smtp.<region>.amazonaws.com (e.g., email-smtp.us-east-1.amazonaws.com) |
| Port | 587 |
| Encryption | STARTTLS |
| Username | SES SMTP username (generated in the SES console) |
| Password | SES SMTP password (generated with the username) |

> Note: SES requires you to verify your sending domain and, for production sending, request a sending limit increase.

Mailgun

| Field | Value |
|---|---|
| Relay Host | smtp.mailgun.org |
| Port | 587 |
| Encryption | STARTTLS |
| Username | Your full Mailgun SMTP login (e.g., postmaster@mg.example.com) |
| Password | Your Mailgun SMTP password |



How the Relay Works

When a Custom SMTP Relay is enabled:

  1. A user or application sends mail to a local address (e.g., PHP mail(), a mail client, or webmail).
  2. Postfix receives the message and, instead of delivering directly to the recipient's mail server, forwards it to the configured relay.
  3. The relay authenticates with the provider, accepts the message, and delivers it to the final recipient.
  4. Delivery reports and bounces are handled by the provider and may be returned to the sender.
> Note: The relay only affects outgoing mail. Incoming mail for hosted domains is still delivered directly to GoAdmio's Dovecot. This is the desired behavior for most setups.

Verify the Relay Is Working

Send a test message

From a hosted account, send an email to an external address (e.g., a Gmail account). Check:

  • The message arrives (not in spam)
  • The headers show the relay provider as the sending server

Check the mail log

```bash
tail -f /var/log/maillog

↑