EMAIL TESTING WITH SMTPBOX

Test the email Laravel actually sends.

Capture mailables, notifications and queued email from your development or staging application in a shared SMTPBox inbox.

2,500 emails per month free · 5 team members · No card required

Choose the right kind of Laravel email test

Use Laravel mail fakes for fast tests that check whether your code requested an email. Use an SMTP sandbox when you need to exercise the configured transport and inspect the actual message your application produces.

This is useful for registration notices, password reset notifications, invoices and mailables with attachments. A shared staging inbox also lets QA inspect a message without access to a developer computer.

Configure the development mailer

MAIL_MAILER=smtp
MAIL_HOST=smtp.smtpbox.dev
MAIL_PORT=587
MAIL_USERNAME=your_inbox_username
MAIL_PASSWORD=your_inbox_password
MAIL_FROM_ADDRESS=hello@example.test
MAIL_FROM_NAME="Example app"

Use STARTTLS with port 587. Current Laravel skeletons use MAIL_SCHEME=smtp; older applications may use MAIL_ENCRYPTION=tls. Check your own config/mail.php and follow the Laravel setup guide.

Inspect a real application journey

  1. Set the SMTPBox credential in your development environment.
  2. Clear stale configuration and restart long-running queue workers.
  3. Trigger a registration or password reset for a synthetic test account.
  4. Inspect the subject, recipient, text and HTML in the inbox.
  5. Check that links point to the development application.

Test more than a subject line

Look for missing template values, incorrect asset URLs, the wrong reply-to address and attachments with unexpected filenames. Then use the email testing API to turn critical checks into assertions.

Why Laravel mail can appear to disappear

A queued notification may be waiting for a worker. A running worker may still hold the old SMTP settings. A cached config or MAIL_URL can override the values you just changed. If SMTP authentication fails, use the inbox username and password, not your SMTPBox login.

Keep environments separate

Give local development, staging and CI their own inbox credentials. Change only non-production mail settings: production must continue using your delivery provider. SMTPBox captures email rather than delivering it to your users.

Start with a free inbox

Free includes 2,500 captured emails per month and 7-day retention. Unlimited is £14.99 per month with 30-day retention, subject to fair use.

Create your SMTPBox account Compare plans

Updated