Skip to main content
ESC

Searching...

Quick Links

Type to search • Press to navigate • Enter to select

Keep typing to search...

No results found

No documentation matches ""

Email Configuration

Set up email sending for notifications and verification.

Dec 5, 2025

Reward Loyalty sends emails for registration, password resets, and notifications. Configure your email provider in the .env file.

Configuration

Locate the mail section in your .env file:

MAIL_MAILER=smtp
MAIL_HOST=smtp.example.com
MAIL_PORT=587
MAIL_USERNAME=your_username
MAIL_PASSWORD=your_password
MAIL_ENCRYPTION=tls
MAIL_FROM_ADDRESS="hello@yourdomain.com"
MAIL_FROM_NAME="${APP_NAME}"

Common Providers

SMTP (General)

MAIL_MAILER=smtp
MAIL_HOST=your-smtp-server.com
MAIL_PORT=587
MAIL_USERNAME=your_username
MAIL_PASSWORD=your_password
MAIL_ENCRYPTION=tls

Gmail

MAIL_MAILER=smtp
MAIL_HOST=smtp.gmail.com
MAIL_PORT=587
MAIL_USERNAME=your@gmail.com
MAIL_PASSWORD=your_app_password
MAIL_ENCRYPTION=tls

Note: Gmail requires an App Password, not your regular password. Enable 2FA and generate an App Password in your Google account settings.

Mailgun

MAIL_MAILER=mailgun
MAILGUN_DOMAIN=your-domain.mailgun.org
MAILGUN_SECRET=your-api-key

Spam Prevention

If registration emails land in spam:

  1. Check your domain's SPF and DKIM records
  2. Use a reputable email provider
  3. Avoid spam trigger words in email content

Registration Link Setting

Long URLs in registration emails may trigger spam filters. If you have deliverability issues:

APP_REGISTRATION_EMAIL_LINK=false

This disables the automatic login link in registration emails.

Testing

After configuring, test email sending:

  1. Register a new test account
  2. Check if the verification email arrives
  3. Verify it doesn't land in spam

Troubleshooting

Emails not sending:

  • Verify credentials are correct
  • Check your provider's sending limits
  • Review storage/logs/laravel.log for errors

Emails in spam:

  • Configure SPF/DKIM records
  • Use a dedicated sending domain
  • Consider a transactional email service