tools//Google//Gmail API

The Gmail API is a REST API for programmatic access to Gmail mailboxes: it reads, sends, labels, searches and manages email without the Gmail UI. The user talks directly to Google, gives permission through OAuth 2.0, and Google hands the app a token to access that user's data; the app never sees the user's password, only the scoped token.


The Gmail API is a REST API for programmatic access to Gmail mailboxes: it reads, sends, labels, searches and manages email without the Gmail UI. The user talks directly to Google, gives permission through OAuth 2.0, and Google hands the app a token to access that user's data; the app never sees the user's password, only the scoped token.

Having the Gmail API in a service is like having an appendix of Google inside the app.

OAuth 2.0 access is scoped (read-only, send-only or full access), and users must consent explicitly.

Its common uses are automated email parsing (invoices, receipts), CRM integrations, notification systems and email migration tools.

The Watch API sends push notifications through Google Cloud Pub/Sub when new mail arrives, so no polling is needed.

Quotas allow 250 sends a day for regular accounts and more for Workspace, with rate limits per user and per project. For heavy batch processing (scanning thousands of emails, for instance), a Vercel Function will time out, and a job queue like Inngest or Trigger.dev is needed to process the work in chunks.

The Gmail API is based on HTTP and JSON, and has nothing to do with SMTP. For SMTP relay (legacy apps, printers, IoT devices), Gmail's SMTP server is a separate thing.

The API is managed through the Google Cloud Console (API enablement, credentials, quotas).