Visual RFC.
ALL RFCs / RFC 9051
Read the RFC ↗

RFC 9051 / START HERE

IMAP4rev2 mailbox access, before the details

IMAP: Internet Message Access Protocol

IMAP lets an email app access and manage messages stored on a mail server. This RFC describes IMAP4 revision 2.

The idea in one picture

  1. A mail app connects to a mailbox

  2. IMAP reads and updates server state

  3. Devices can see shared mail state

A simplified picture of the idea; the chapters explain the actual mechanisms.

Why it exists

People often read the same mailbox from several devices. Keeping mail on a server lets clients synchronize folders, messages, and flags.

A familiar example

Marking a message as read on your laptop can be reflected in the mailbox your phone accesses.

Helpful background

You can start here without reading another RFC. If these ideas are unfamiliar, these short introductions may help.

What you’ll learn next

Begin with chapter one, or choose a topic.

  1. Session and mailbox statesAuthentication and mailbox selection enable different commands.
  2. UIDs versus sequence numbersSequence numbers track current positions; UIDs support persistent synchronization.
  3. Selective FETCH and SEARCHA client can retrieve metadata or a selected body section instead of downloading every complete message.
  4. Flags and deletionFlags describe server-side message state; deletion marking and expunging are separate operations.
  5. Unsolicited updates and resyncThe server can report changes while a client is connected, and saved UID state helps reconnecting clients.
Start with chapter one →

This introduction explains RFC 9051 (2021). Read the original RFC ↗