Google SMTP Server – How to Send Emails for Free

Google's GMail SMTP server is a free service for anyone who has a GMail account. You can use this free SMTP server to send emails from your favourite web application.

If you don’t have a GMail account, you can create one at the GMail account creation page.

Then all you need to do is configure your mail client to use GMail for outgoing mail server. The details you should use are:

Outgoing Mail (SMTP) Server:

Use Authentication: Yes

Use Secure Connection: Yes (this can be TLS or SSL depending on your mail client)

Username: your GMail account, i.e.

Password: your GMail password

Port: 465 or 587

In case you use Google Apps with your domain name and you have created email accounts inside, you should use email account with the Username: field, i.e.

The same email settings can be used with the email functionality of website application such as Joomla, PrestaShop etc. If you have any troubles configuring your website applications with the above settings you can contact the SiteGround Technical Support team and they will be glad to assist you.

Setting up your email is easy when you have the right host by your side. If you need a reliable partner to help you resolve email issues and provide expert support, check out our email hosting services.


  1. Reply May 27, 2015 / 20:38 MagdySiteGround Team


  2. Reply September 16, 2015 / 23:03 Felix AlvaradoSiteGround Team

    Hello, i have a question to ask. I can use this free server SMTP to send emails from an application like some made it in MATLAB ?

    • Reply September 17, 2015 / 09:09 Hristo PandjarovSiteGround Team


  3. Reply September 18, 2015 / 12:43 Mike WisemanSiteGround Team

    This doesn't work for me. Says "Authentication failed. Please check username/password."
    I am specifying my correct gmail username and password.

    • Reply September 23, 2015 / 09:55 Ivan YordanovSiteGround Team

      Please make sure that you have specified the correct SMTP host: Your application should be working properly with the configuration from the article. However, if there is a specific problem - do not hesitate to open a support ticket with the details about the case - we will be happy to assist you.

  4. Reply September 30, 2015 / 02:09 BenSiteGround Team

    Hi there,
    I am getting an authentication issue with using gmail smtp.
    My project is hosted at for dev purposes, but each time I attempt to use gmail smtp to send my mail, the authentication is blocked and I am notified that there is an unknown device accessing my account.
    I have enabled the setting to allow non-trusted apps, but to no avail will gmail smtp allow me to authenticate.
    Any ideas?

    • Reply October 2, 2015 / 05:48 Hristo PandjarovSiteGround Team

      Probably something is not set right with the domain. Please, open a ticket in our Help Desk so we can investigate in details.

  5. Reply October 4, 2015 / 13:42 Roberto RochaSiteGround Team

    I cant set my DVR to send motion detection e-mails.
    It does not work.
    Test ... Failed
    The server does not support the authentication mode used by the device
    Is there any thing that i can do?

    • Reply October 5, 2015 / 05:33 Hristo PandjarovSiteGround Team

      I would recommend that you check the manual of the DVD or contact the support of the company that has created it for further assistance. That should be easily doable if configured correctly.

  6. Reply October 19, 2015 / 18:21 kachySiteGround Team

    i tried it on turbo mailer,following ur instructions but it always say "applicationerror: no connection to smtp server,8, Eof occurred in violation protocol

    • Reply October 20, 2015 / 06:13 Hristo PandjarovSiteGround Team

      I would recommend that you contact your applicatiom developers for additional assistance on that matter.

  7. Reply October 19, 2015 / 19:46 ClareSiteGround Team

    I have tried this on my phone and I get "Unable to set up account. Authentication failed" message on the phone and an email to my gMail account saying "Someone just tried to sign in to your Google Account from an app that doesn't meet modern security standards". Is there a way to overcome that please?

    • Reply October 20, 2015 / 15:42 Ivan YordanovSiteGround Team

      It seems that this is a common issue. There is a detailed explanation provided from Google - you can check it at the Following Link

  8. Reply October 19, 2015 / 21:33 BenSiteGround Team

    For the people having issues. It's likely that you have to update your IMAP settings to enabled.

  9. Reply October 21, 2015 / 12:59 shekharSiteGround Team

    Failed to sent email.
    javax.mail.AuthenticationFailedException: 534-5.7.14 Please log in via your web browser and
    534-5.7.14 then try again.
    534-5.7.14 Learn more at
    534 5.7.14 pj10sm9137195pbc.59 - gsmtp

    at com.sun.mail.smtp.SMTPTransport$Authenticator.authenticate(
    at com.sun.mail.smtp.SMTPTransport.authenticate(
    at com.sun.mail.smtp.SMTPTransport.protocolConnect(
    at javax.mail.Service.connect(
    at javax.mail.Service.connect(
    at javax.mail.Service.connect(
    at javax.mail.Transport.send0(
    at javax.mail.Transport.send(
    at sendmail.SendMail.SendMail(
    at sendmail.SendMail.main(
    BUILD SUCCESSFUL (total time: 9 seconds)
    I am getting above problem even after setting everything correctly

    • Reply October 23, 2015 / 10:44 Ivan YordanovSiteGround Team

      It seems to be related to the application you are using for connecting to Gmail. Please open a support ticket if you are using our services and describe the case in details - we will be happy to assist you. Otherwise, you will ned to contact application's developer or host in order to investigate the issue.

  10. Reply October 23, 2015 / 14:51 WaelSiteGround Team

    Hello there, I am sorry but I tried everything there will be limitation on number of message you can send how can I increase messages!

    • Reply October 25, 2015 / 12:51 Hristo PandjarovSiteGround Team

      I am afraid that's a Google limitation so you don't have any actual control over it.

  11. Reply October 28, 2015 / 10:19 WIPocketSiteGround Team

    Is there any api to send e-mails by googles SMTP server that uses different ports?

    • Reply November 3, 2015 / 13:31 Ivan YordanovSiteGround Team

      You can review more detailed information about the Google SMTP configuration at:

      and the documentation for the Gmail API is available at:

  12. Reply November 1, 2015 / 09:42 LotionSiteGround Team

    Will send test email successfully but later will not be sending any further mails...any idea

    • Reply November 2, 2015 / 11:20 Marina YordanovaSiteGround Team

      Unfortunately this information is not enough to recreate the issue. We would need more details in order to suggest a solution.

  13. Reply November 6, 2015 / 06:16 grahamSiteGround Team

    Google has upgraded security and this will no longer work as easily as using the outgoing with a username (email address) and password. This is a massive headache for business users of google apps for work... however there is a simple work around for standard gmail users.

  14. Reply November 7, 2015 / 17:19 CharisSiteGround Team

    What is the simple work around for standard gmail users ?
    because i think most of as have same problem. everything work ok until 1st of november

    • Reply November 10, 2015 / 08:47 escalationsSiteGround Team

      Check your gmail settings and verify applications are allowed to connect to your account. You can do this via your google settings section.

  15. Reply November 18, 2015 / 02:58 Jason FoxSiteGround Team


    I had a similar problem as people have been describing above, because of the new 2-factor requirements, I had to generate an app specific password:

    More here:

    I was getting mail set up for my security DVR just like a poster above. Hope this helps!

    • Reply January 27, 2016 / 18:11 BernardSiteGround Team

      we have a winner!

  16. Reply November 19, 2015 / 00:30 kdySiteGround Team

    i have this working..but the emails come in with a 14 hour earlier time stamp...ive checked time settings every thing looks good, guessing this maybe pulling time on the smtp server...anyone know if it is correctable..?

    • Reply November 20, 2015 / 08:26 Hristo PandjarovSiteGround Team

      That's a Google setting, you should check the options of your email account.

  17. Reply December 10, 2015 / 12:57 MartinSiteGround Team

    This worked for me, but with one huge caveat.

    I am using Contact Form 7 – and even if I do specify another "From" adress, it still takes my gmail-adress as a from-sender. Which is not good.

    How can this be solved? Seems like the Oauth-email overrides the Contact Form 7.
    Even the "Test Email" gives me wrong From-address.

    • Reply December 11, 2015 / 14:03 Hristo PandjarovSiteGround Team

      Please, contact the plugin developers and/or check its documentation for more information on that matter.

  18. Reply December 25, 2015 / 18:35 TaoSiteGround Team

    what's the flow restriction on this smtp relay, i.e. how many emails can it sent per hour/ per day before it triggers spamming alert?

    • Reply December 28, 2015 / 07:12 Hristo PandjarovSiteGround Team

      That's a setting in the Google servers that we don't have access to.

    • Reply January 24, 2016 / 10:38 OliaSiteGround Team

      99 emails a day

  19. Reply January 24, 2016 / 11:38 numirSiteGround Team

    can i use this server STMP to sendblaster program to send emails ?

    • Reply January 25, 2016 / 07:12 Hristo PandjarovSiteGround Team

      I guess so, if the application supports it.

  20. Reply February 3, 2016 / 21:42 MichaelSiteGround Team

    Gmail accounts aren't authenticating anymore, i think this is their way of forcing users to pay for Googles Apps if they want to relay

    SASL authentication failed; server[] said: 534-5.7.14 Please log in via your web browser and?534-5.7.14 then try again.?534-5.7.14 Learn more at?534 5.7.14 l62sm12044873pfj.7 - gsmtp

    • Reply February 5, 2016 / 08:23 Ivan StefanovSiteGround Team

      Michael, please submit a technical support ticket as we should investigate the issue and check the server logs. I'm pretty positive that the authentication would be successful, once we verify that the connection to could be established for your account.

* (Required)