SMTP Setup
kuploy-cloud requires SMTP for email delivery in production. Email is used for user verification, password resets, billing alerts, and notification channels.
Why SMTP Is Required
Without SMTP configured:
- Users cannot verify their email addresses
- Password reset flows won't work
- Email-based billing notifications are disabled
- Team invite emails cannot be sent
Configuration Methods
SMTP can be configured through the admin dashboard or environment variables. Dashboard settings take priority over environment variables.
Method 1: Admin Dashboard (Recommended)
- Log in as a platform admin
- Go to Admin → SMTP
- Enter your SMTP settings
- Click Test to verify
- Click Save
Settings are stored encrypted in the database and take effect immediately — no restart required.
Method 2: Environment Variables
Set these in your .env file or Kubernetes secret:
| Variable | Description | Example |
|---|---|---|
SMTP_HOST | SMTP server hostname | smtp.mailgun.org |
SMTP_PORT | SMTP port | 587 |
SMTP_USER | Authentication username | postmaster@mg.example.com |
SMTP_PASS | Authentication password | your-smtp-password |
SMTP_FROM | Sender email address | noreply@example.com |
SMTP_FROM_NAME | Sender display name | My Platform |
Method 3: Kubernetes Secret
For Kubernetes deployments:
# Encode values
echo -n "smtp.mailgun.org" | base64
# Patch the secret
kubectl patch secret kuploy-secrets -n kuploy -p '{
"data": {
"SMTP_HOST": "<base64-host>",
"SMTP_PORT": "<base64-port>",
"SMTP_USER": "<base64-user>",
"SMTP_PASS": "<base64-pass>",
"SMTP_FROM": "<base64-from>"
}
}'
# Restart to apply
kubectl rollout restart deployment/kuploy -n kuploy
Recommended Providers
Any SMTP service works. Common choices:
| Provider | Free Tier | Notes |
|---|---|---|
| Mailgun | 100 emails/day | Popular for transactional email |
| SendGrid | 100 emails/day | Easy setup, good deliverability |
| Amazon SES | 62,000/month (with EC2) | Cheapest at scale |
| Postmark | 100 emails/month | Focused on transactional email |
| Resend | 3,000 emails/month | Modern API, developer-friendly |
Testing
After configuration, verify SMTP is working:
- Admin dashboard test — Go to Admin → SMTP → click Test
- Sign-up flow — Create a new user account and check for the verification email
- Check spam folders — Transactional emails sometimes land in spam initially
Troubleshooting
Emails not sending
- Verify SMTP credentials are correct
- Check that the SMTP port is not blocked by your firewall
- Ensure the "from" address is verified with your SMTP provider
Emails going to spam
- Set up SPF, DKIM, and DMARC records for your sending domain
- Use a dedicated sending domain (not a free email provider)
- Ensure the "from" address matches your domain
Connection timeout
- Port 587 (STARTTLS) is recommended — port 25 is often blocked
- Check that your Kubernetes cluster allows outbound connections on the SMTP port
- Verify the SMTP host is resolvable from within your cluster