Gmail & Google Apps SMTP Settings in OpenCart


OpenCart is one of the best-performing shopping cart scripts. Fortunately, you can use your existing Gmail or Google Apps email account in Opencart.

To ensure it work, correct SMTP Server details are required.

Email setting page can be found by browsing

System  Settings  Edit  Mail

The table below is the setting for using Gmail or Google Apps email account with Opencart.

Gmail Google Apps
Mail Protocol SMTP SMTP
Mail Parameters
SMTP Host ssl://smtp.gmail.com ssl://smtp.gmail.com
SMTP Username <your email>@gmail.com <your email>@<your domain>
SMTP Password <your password> <your password>
SMTP Port 465 465
SMTP Timeout 5 5




12 comments… add one
  • Thanks,save my time. this correct setting for gmail.com email.

    Reply
  • Hi, thanks for this. I am using google apps have been wrestling with this for 3 days on and off now, no matter what I try, getting the error:

    Notice: Error: Password not accepted from server! in /home/XXXXXX/public_html/xxxxxxx/system/library/mail.php on line 251

    I have tried the disabling the ;log in challenge still nothing. Any help would be most appreciated

    Reply
    • Have you try to login to the said account by using your browser by using the same password? Sometimes Google require you to verify the login from other IP.

      Without verifying, Google block login attempt.

      Reply
  • hi i m using google apps getting error

    Notice: Error: Password not accepted from server! in /home/xxxxx/public_html/xxxxx/system/library/mail.php on line 501

    help would be most appreciated

    Reply
    • make sure you entered the right username & password.

      Reply
  • Goodmoringin,
    I tried to put SMTP. 597 and the system gives me this error:

    2016-01-27 8:05:24 – PHP Warning: fsockopen(): SSL: crypto enabling timeout in ***/public_html/eshop/system/library/mail.php on line 170
    2016-01-27 8:05:24 – PHP Warning: fsockopen(): Failed to enable crypto in ***/public_html/eshop/system/library/mail.php on line 170
    2016-01-27 8:05:24 – PHP Warning: fsockopen(): unable to connect to ssl://smtp.gmail.com:587 (Unknown error) in ***/public_html/eshop/system/library/mail.php on line 170
    2016-01-27 8:05:24 – PHP Notice: Error: (0) in ***/public_html/eshop/system/library/mail.php on line 173

    If I try with SMTP: 465 gives me this error:
    Notice: Error: Password not accepted from server! in /home/kids2/public_html/eshop/system/library/mail.php on line 289

    But the password is correct.

    what should I do?
    Thank you!

    Reply
    • Did your key-in the right username?

      Reply
  • two weeks a go, the mails from my page have label, this say “the sender of this message could not be” before this not displayed

    im use opencart2 in mi page and not change nothingness in the page or services

    Reply
  • If you get an error:
    “Error: Password not accepted from server!”
    This is blocked by Gmail:
    https://support.google.com/accounts/answer/6010255
    The reason is that Gmail believes the applkication which tries to get an access is not safe.
    You can allow “not safe applications” at your risk. Find instruction at the link above.

    Reply
  • Another solution (which worked for us) was to use:

    tls://smtp.gmail.com
    port 587

    Reply
  • We setup all settings for SMTP , received errors will signup a new user with an order.
    Once you setup your details in Opencart

    Go to Gmail and login to the account that you used for your SMTP configuration in Step 2.
    Once logged in, go to “https://accounts.google.com/b/0/DisplayUnlockCaptcha”

    Give it access to use GMail. go back place a new order, you might get pass with SMTP if you do not CHOOSE , Mail Protocol as MAIL instead of SMTP. All other settings remains the same. IT worked for us.

    Reply
  • TESTED and this solution is also WORKING.
    By
    David Carta 
    March 21, 2017, 12:43 am
    Another solution (which worked for us) was to use:

    tls://smtp.gmail.com
    port 587

    Reply

Leave a Comment