Skip to content

priyanage-official/laravel-mailExample

Repository files navigation

Build Status Total Downloads Latest Stable Version License

Gmail Configurations

  • Login to your Gmail account.
  • On the right-top corner click your profile picture. Go to "Manage Your Google Account".
  • Click "Security" on the left menu.
  • Under "How you sign in to Google" go to "2-Step Verification".
  • Enter your password(If asked) then scroll down to "App passwords".
  • Click "App passwords" then under "To create a new app-specific password.." create an app password with any name you want ex. "LaravelApp".
  • On successful creation, a popup will show you with your password. Copy and save it.

Your Project Configurations

In your project .env file change the following.

  • MAIL_MAILER=smtp
  • MAIL_HOST=smtp.gmail.com
  • MAIL_PORT=587 (if tls, 465 for ssl)
  • MAIL_USERNAME=YOUR-EMAIL-ID
  • MAIL_PASSWORD='YOUR-APP-PASSWORD'
  • MAIL_ENCRYPTION=tls
  • MAIL_FROM_ADDRESS=YOUR-EMAIL-ID
  • MAIL_FROM_NAME="${APP_NAME}"

License

The Laravel framework is open-sourced software licensed under the MIT license.

About

This is a simple send mail laravel example using SMTP

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published