Skip to content
Mbox Viewer

Gmail labels

labels

Gmail's tagging system that assigns one or more labels to each message, serving the role that folders play in traditional email clients. A single message can carry multiple labels simultaneously.

Unlike traditional email clients that organize messages into exclusive folders, Gmail uses labels — essentially tags that can be applied to any message in any combination. A message can be in Inbox, starred, and also tagged with a custom label such as "Receipts" at the same time. System labels like Sent, Drafts, Spam, and Trash are also implemented as labels internally.

When Google Takeout exports Gmail, it encodes label information in the MBOX file using a non-standard X-Gmail-Labels header on each message. This header contains a comma-separated list of all labels applied to that message. Standard MBOX readers that do not understand this header will still display the messages but will lose the label organization.

Mbox Viewer reads the X-Gmail-Labels header and reconstructs the label hierarchy in the sidebar, allowing you to browse your archive by label just as you would in Gmail. You can also search by label using the label: filter, or combine it with other criteria such as from:, subject:, or date ranges to narrow results in large archives.

Related terms

Read your MBOX files on your Mac