IMAP, POP, and SMTP  |  Gmail  |  Google for Developers (2024)

For non-Gmail clients, Gmail supports the standard IMAP, POP, and SMTP protocols. The Gmail IMAP, POP, and SMTP servers have been extended to support authorization via the industry-standard OAuth 2.0 protocol.

Protocol

IMAP, POP, and SMTP use the standard Simple Authentication and Security Layer (SASL), using the built-in the native IMAP AUTHENTICATE, POP AUTH, and SMTP AUTH commands, to authenticate users. The SASL XOAUTH2 mechanism enables clients to provide OAuth 2.0 credentials for authentication. The SASL XOAUTH2 protocol documentation describes the SASL XOAUTH2 mechanism in great detail, and libraries and samples which have implemented the protocol are available.

Incoming connections to the IMAP server at imap.gmail.com:993 and the POP server at pop.gmail.com:995 require SSL. The outgoing SMTP server, smtp.gmail.com, supports TLS. If your client begins with plain text, before issuing the STARTTLS command, use port 465 (for SSL), or port 587 (for TLS).

Session length limits

Gmail POP sessions are limited to about 7 days. Gmail IMAP sessions are limited to about 24 hours. If the session was authenticated using OAuth credentials, it's limited to about the validity period of the access token used (usually 1 hour). A session in this context is one continuous TCP connection.

See Also
Redirecting

When the time elapses and the session expires, Gmail closes the connection with a message saying that the session expired. After that, the client can reconnect, authenticate again, and continue. If using OAuth, make sure that the access token used is valid (if you try to use an access token older than 1 hour, it might be invalid).

Libraries and Samples

Accessing mail using IMAP or POP and sending mail using SMTP is often done using existing IMAP and SMTP libraries for convenience. As long as these libraries support the Simple Authentication and Security Layer (SASL), they should be compatible with the SASL XOAUTH2 mechanism supported by Gmail.

In addition to the SASL XOAUTH2 protocol documentation, you may also want to read Using OAuth 2.0 to Access Google APIs for further information on implementing an OAuth 2.0 client.

The Libraries and Samples page provides code samples in a variety of popular languages using the SASL XOAUTH2 mechanism with either IMAP or SMTP.

IMAP, POP, and SMTP  |  Gmail  |  Google for Developers (2024)
Top Articles
Stronghold
Axis Bank Ltd. Latest Shareholding Pattern – Promoter, FII, DII, Mutual Fund. Who owns, bought or sold Axis Bank Ltd. Shares?
Walgreens Harry Edgemoor
Methstreams Boxing Stream
Star Sessions Imx
Angela Babicz Leak
Gabrielle Abbate Obituary
Ncaaf Reference
Craigslist Estate Sales Tucson
Power Outage Map Albany Ny
Mission Impossible 7 Showtimes Near Regal Bridgeport Village
Nier Automata Chapter Select Unlock
Saw X | Rotten Tomatoes
10 Free Employee Handbook Templates in Word & ClickUp
Restaurants Near Paramount Theater Cedar Rapids
Sivir Urf Runes
Snow Rider 3D Unblocked Wtf
Houses and Apartments For Rent in Maastricht
Brett Cooper Wikifeet
Craigslist Portland Oregon Motorcycles
Watch The Lovely Bones Online Free 123Movies
Fsga Golf
Today Was A Good Day With Lyrics
Myhr North Memorial
Military life insurance and survivor benefits | USAGov
Spn 520211
Stoney's Pizza & Gaming Parlor Danville Menu
Egizi Funeral Home Turnersville Nj
Gran Turismo Showtimes Near Marcus Renaissance Cinema
Haunted Mansion Showtimes Near Epic Theatres Of West Volusia
Roseann Marie Messina · 15800 Detroit Ave, Suite D, Lakewood, OH 44107-3748 · Lay Midwife
Gopher Hockey Forum
R/Mp5
Nurtsug
Otis Offender Michigan
Sedano's Supermarkets Expands to Orlando - Sedano's Supermarkets
Litter-Robot 3 Pinch Contact & DFI Kit
Hair Love Salon Bradley Beach
Www Violationinfo Com Login New Orleans
Whitehall Preparatory And Fitness Academy Calendar
Raisya Crow on LinkedIn: Breckie Hill Shower Video viral Cucumber Leaks VIDEO Click to watch full…
Tiny Pains When Giving Blood Nyt Crossword
Www Craigslist Com Brooklyn
Miami Vice turns 40: A look back at the iconic series
Deepwoken: How To Unlock All Fighting Styles Guide - Item Level Gaming
Rescare Training Online
Sky Dental Cartersville
Cryptoquote Solver For Today
De Donde Es El Area +63
Tyrone Dave Chappelle Show Gif
Arre St Wv Srj
Latest Posts
Article information

Author: Msgr. Refugio Daniel

Last Updated:

Views: 5759

Rating: 4.3 / 5 (74 voted)

Reviews: 81% of readers found this page helpful

Author information

Name: Msgr. Refugio Daniel

Birthday: 1999-09-15

Address: 8416 Beatty Center, Derekfort, VA 72092-0500

Phone: +6838967160603

Job: Mining Executive

Hobby: Woodworking, Knitting, Fishing, Coffee roasting, Kayaking, Horseback riding, Kite flying

Introduction: My name is Msgr. Refugio Daniel, I am a fine, precious, encouraging, calm, glamorous, vivacious, friendly person who loves writing and wants to share my knowledge and understanding with you.