SMTP guides
Laravel
Point Laravel's Mail facade at usend over SMTP.
Laravel's mail system works with usend out of the box. Settings used on this page: host smtp.usend.et, port 587 or 465, username usend, password your API key. Reference: Send with SMTP.
Configure .env
MAIL_MAILER=smtp
MAIL_HOST=smtp.usend.et
MAIL_PORT=587
MAIL_USERNAME=usend
MAIL_PASSWORD=us_123456789
[email protected]
MAIL_FROM_NAME=AcmeRecent Laravel versions choose encryption from the port: 465 uses implicit TLS and 587 uses STARTTLS. On older versions also set MAIL_ENCRYPTION=tls for 587 or ssl for 465. To force implicit TLS in newer versions, set MAIL_SCHEME=smtps.
Clear cached configuration after changing it:
php artisan config:clearSend
Nothing in your code changes:
use Illuminate\Support\Facades\Mail;
Mail::to('[email protected]')->send(new OrderShipped($order));
// or a quick text mail
Mail::raw('It works!', fn ($m) => $m->to('[email protected]')->subject('Hello from usend'));Queue mail with ->queue(...) so sending never slows a request. Use a sending_access key limited to your domain for the password.
Check it
php artisan tinker
>>> Mail::raw('Test', fn ($m) => $m->to('[email protected]')->subject('Test'));The message appears in the usend dashboard under Emails.
Troubleshooting
| Symptom | Cause |
|---|---|
535 Invalid API key | The password is not a current key, or config:cache holds an old value. |
554 ... domain is not verified | MAIL_FROM_ADDRESS is not on a verified domain. |
| Sends to outsiders refused | Your organization is in the sandbox. |
| Connection timeout | Your host blocks outbound 587/465. Use the HTTP API instead. |