Skip to main content

🚀 Quickstart

Connect to Gmail with Nango and see data flow in 2 minutes.
1

Create the integration

In Nango (free signup), go to Integrations -> Configure New Integration -> Gmail.
Nango has credentials you can use for testing. Activate them in the dashboard.
2

Authorize Gmail

Go to Connections -> Add Test Connection -> Authorize, then log in to Gmail. Later, you’ll let your users do the same directly from your app.
3

Call the Gmail API

Let’s make your first request to the Gmail API (fetch the profile of the currently signed-in user). This request will return basic details about the authenticated user, such as their email address and message/thread counts. Replace the placeholders below with your secret key, integration ID, and connection ID:
curl "https://api.nango.dev/proxy/gmail/v1/users/me/profile" \
  -H "Authorization: Bearer <NANGO-SECRET-KEY>" \
  -H "Provider-Config-Key: <INTEGRATION-ID>" \
  -H "Connection-Id: <CONNECTION-ID>"
Or fetch credentials dynamically via the Node SDK or API.✅ You’re connected! Check the Logs tab in Nango to inspect requests.
4

Implement Nango in your app

Follow our Auth implementation guide to integrate Nango in your app.To obtain your own production credentials, follow the setup guide linked below.

📚 Gmail Integration Guides

Nango maintained guides for common use cases. Official docs: Gmail API docs

🧩 Pre-built syncs & actions for Gmail

Enable them in your dashboard. Extend and customize to fit your needs.

Others

Function nameDescriptionTypeSource code
filtersSync Gmail mailbox filters and their criteria or actions.Sync🔗 Github
labelsSync built-in and user-created Gmail labels.Sync🔗 Github
messagesSync Gmail messages with an initial backfill followed by history-based incremental updates.Sync🔗 Github
send-as-aliasesSync configured Gmail send-as aliases and alias settingsSync🔗 Github
threadsSync Gmail conversation threads with full message hydrationSync🔗 Github