nativeInstallermagento

Install the Magento Magepal SMTP extension

Before running the commands shown on this page, you should load the Bitnami stack environment by executing the installdir/use_APPNAME script (Linux and MacOS) or by clicking the shortcut in the Start Menu under “Start -> Bitnami APPNAME Stack -> Application console” (Windows). On OS X VMs, the installation directory is /opt/bitnami and OS X VM users can click the “Open Terminal” button to run commands. Learn more about the Bitnami stack environment and about OS X VMs.

NOTE: The Approach A sections referred to below do not apply to Bitnami native installers. Users of Bitnami native installers should refer only to the Approach B sections.

Before you can install any extension in Magento 2, you must create a Magento Marketplace account and an access key pair in the “Access Keys” section.

Once you have your Magento Marketplace keys ready, proceed to install the extension as follows:

  • At the console, install the Magepal SMTP extension using the commands below, depending on your installation type:

    • Approach A (Bitnami installations using system packages):

        $ cd installdir/magento
        $ sudo composer require magepal/magento2-gmailsmtpapp
      
    • Approach B (Self-contained Bitnami installations):

        $ cd installdir/apps/magento/htdocs
        $ sudo composer require magepal/magento2-gmailsmtpapp
      

    The system will prompt for authentication. Use your Magento Marketplace keys as described in the Magento documentation and proceed to download the extension.

  • Once this process is complete, update the Magento configuration to add the new extension as shown below:

      $ sudo magento-cli module:enable --clear-static-content MagePal_GmailSmtpApp
      $ sudo magento-cli setup:upgrade
    
  • Log in to the Magento administration panel.

  • Navigate to the “Stores -> Configuration” page.

  • Navigate to the “Magepal -> SMTP Configuration” section.

  • Set the “Enable” field to “Yes”.

  • Enter the details for your SMTP host. For example, use the following configuration for Gmail. Replace USERNAME and PASSWORD with your Gmail account username and password respectively.

      Authentication method: LOGIN
      SSL type: TLS
      SMTP Host: smtp.gmail.com
      SMTP Port: 587
      Username: USERNAME@gmail.com
      Password: PASSWORD
    
  • Use the “Test Email Server Configuration Settings” section to verify that your email configuration is correct.

  • Once verified, click “Save Config” to save the configuration.

For more information and troubleshooting, refer to the extension documentation.

NOTE: If you are using Gmail as the outbound email server, your application’s attempts to send outgoing emails may be blocked by Gmail if it considers the authentication attempts to be suspicious. When this happens, you will receive a Gmail security alert at the corresponding Gmail address. To proceed, you will need to manually confirm the validity of the authentication attempt before Gmail will permit the application to send outbound emails. For more information on this and other Gmail issues related to outbound email from your application, refer to our Gmail SMTP troubleshooting page.

Last modification June 16, 2021