Proof Gmail IMAP (Gimap) supports IMAP IDLE

This content is 14 years old and may not reflect reality today nor the author’s current opinion. Please keep its age in mind as you read it.

So for those of you with capable mail clients (like OS X Mail.app), here’s proof that IMAP IDLE works for delivering push mail:

$ openssl s_client -connect imap.gmail.com:993 -crlf
* OK Gimap ready for requests from 1.2.3.4 0123456789abcdef
. capability
* CAPABILITY IMAP4rev1 UNSELECT IDLE NAMESPACE QUOTA XLIST CHILDREN XYZZY
. OK Thats all she wrote! 0123456789abcdef
. login samj@samj.net letmein
. OK samj@samj.net authenticated (Success)
. examine inbox
* FLAGS (\Answered \Flagged \Draft \Deleted \Seen)
* OK [PERMANENTFLAGS ()]
* OK [UIDVALIDITY 2]
* 4498 EXISTS
* 0 RECENT
* OK [UNSEEN 1431]
* OK [UIDNEXT 25141]
. OK [READ-ONLY] inbox selected. (Success)
. idle
+ idling
---mail sent and deleted here---
* 4499 EXISTS
* 4499 EXPUNGE
* 4498 EXISTS

This is invariably why some clients ‘feel’ more responsive than others, and why you should find an IMAP IDLE capable client.