Gmail
Read and write access to Gmail: fetch and search emails, drafts, labels, threads, and contacts.
- CCM score
- 70 of 100
- GitHub stars
- 81
- tools
- 20
- auth
- Secret needed
- transport
- STDIO
- env vars
- 7
- last updated
- Aug 30, 2026
Own this MCP server? Claim it
What it does
- Reads mail with
GMAIL_FETCH_EMAILS,GMAIL_FETCH_MESSAGE_BY_MESSAGE_ID,GMAIL_LIST_THREADS, andGMAIL_GET_ATTACHMENT, with filtering and pagination - Writes with
GMAIL_CREATE_EMAIL_DRAFT,GMAIL_REPLY_TO_THREAD, andGMAIL_ADD_LABEL_TO_EMAIL; deletion is limited toGMAIL_MOVE_TO_TRASHandGMAIL_DELETE_MESSAGE - Supports OAuth2 for personal accounts and service accounts for Google Workspace, and contacts through
GMAIL_GET_CONTACTS - Designed for triaging inboxes, drafting and sending replies, and organizing mail with labels
Tools
20 toolsPublic tool metadata for what this MCP can expose to an agent.
GMAIL_ADD_LABEL_TO_EMAILAdds and/or removes specified gmail labels for a message; ensure `message id` and all `label ids` are valid (use 'listlabels' for custom label ids).4 params
Adds and/or removes specified gmail labels for a message; ensure `message id` and all `label ids` are valid (use 'listlabels' for custom label ids).
add_label_idsarraymessage_idstringremove_label_idsarrayuser_idstringGMAIL_CREATE_EMAIL_DRAFTCreates a gmail email draft, supporting to/cc/bcc, subject, plain/html body (ensure `is html=true` for html), attachments, and threading.10 params
Creates a gmail email draft, supporting to/cc/bcc, subject, plain/html body (ensure `is html=true` for html), attachments, and threading.
attachmentobjectbccarraybodystringccarrayextra_recipientsarrayis_htmlbooleanrecipient_emailstringsubjectstringthread_idstringuser_idstringGMAIL_CREATE_LABELCreates a new label with a unique name in the specified user's gmail account.6 params
Creates a new label with a unique name in the specified user's gmail account.
background_colorstringlabel_list_visibilitystringlabel_namestringmessage_list_visibilitystringtext_colorstringuser_idstringGMAIL_DELETE_DRAFTPermanently deletes a specific gmail draft using its id; ensure the draft exists and the user has necessary permissions for the given `user id`.2 params
Permanently deletes a specific gmail draft using its id; ensure the draft exists and the user has necessary permissions for the given `user id`.
draft_idstringuser_idstringGMAIL_DELETE_MESSAGEPermanently deletes a specific email message by its id from a gmail mailbox; for `user id`, use 'me' for the authenticated user or an email address to which the authenticated user has delegated access.2 params
Permanently deletes a specific email message by its id from a gmail mailbox; for `user id`, use 'me' for the authenticated user or an email address to which the authenticated user has delegated access.
message_idstringuser_idstringGMAIL_FETCH_EMAILSFetches a list of email messages from a gmail account, supporting filtering, pagination, and optional full content retrieval.9 params
Fetches a list of email messages from a gmail account, supporting filtering, pagination, and optional full content retrieval.
ids_onlybooleaninclude_payloadbooleaninclude_spam_trashbooleanlabel_idsarraymax_resultsintegerpage_tokenstringquerystringuser_idstringverbosebooleanGMAIL_FETCH_MESSAGE_BY_MESSAGE_IDFetches a specific email message by its id, provided the `message id` exists and is accessible to the authenticated `user id`.3 params
Fetches a specific email message by its id, provided the `message id` exists and is accessible to the authenticated `user id`.
formatstringmessage_idstringuser_idstringGMAIL_FETCH_MESSAGE_BY_THREAD_IDRetrieves messages from a gmail thread using its `thread id`, where the thread must be accessible by the specified `user id`.3 params
Retrieves messages from a gmail thread using its `thread id`, where the thread must be accessible by the specified `user id`.
page_tokenstringthread_idstringuser_idstringGMAIL_GET_ATTACHMENTRetrieves a specific attachment by id from a message in a user's gmail mailbox, requiring valid message and attachment ids.4 params
Retrieves a specific attachment by id from a message in a user's gmail mailbox, requiring valid message and attachment ids.
attachment_idstringfile_namestringmessage_idstringuser_idstringGMAIL_GET_CONTACTSFetches contacts (connections) for the authenticated google account, allowing selection of specific data fields and pagination.4 params
Fetches contacts (connections) for the authenticated google account, allowing selection of specific data fields and pagination.
include_other_contactsbooleanpage_tokenstringperson_fieldsstringresource_namestringGMAIL_GET_PEOPLERetrieves either a specific person's details (using `resource name`) or lists 'other contacts' (if `other contacts` is true), with `person fields` specifying the data to return.6 params
Retrieves either a specific person's details (using `resource name`) or lists 'other contacts' (if `other contacts` is true), with `person fields` specifying the data to return.
other_contactsbooleanpage_sizeintegerpage_tokenstringperson_fieldsstringresource_namestringsync_tokenstringGMAIL_GET_PROFILERetrieves key gmail profile information (email address, message/thread totals, history id) for a user.1 params
Retrieves key gmail profile information (email address, message/thread totals, history id) for a user.
user_idstringGMAIL_LIST_DRAFTSRetrieves a paginated list of email drafts from a user's gmail account. use verbose=true to get full draft details including subject, body, sender, and timestamp.4 params
Retrieves a paginated list of email drafts from a user's gmail account. use verbose=true to get full draft details including subject, body, sender, and timestamp.
max_resultsintegerpage_tokenstringuser_idstringverbosebooleanGMAIL_LIST_LABELSRetrieves a list of all system and user-created labels for the specified gmail account.1 params
Retrieves a list of all system and user-created labels for the specified gmail account.
user_idstringGMAIL_LIST_THREADSRetrieves a list of email threads from a gmail account, identified by `user id` (email address or 'me'), supporting filtering and pagination.5 params
Retrieves a list of email threads from a gmail account, identified by `user id` (email address or 'me'), supporting filtering and pagination.
max_resultsintegerpage_tokenstringquerystringuser_idstringverbosebooleanGMAIL_MODIFY_THREAD_LABELSAdds or removes specified existing label ids from a gmail thread, affecting all its messages; ensure the thread id is valid.4 params
Adds or removes specified existing label ids from a gmail thread, affecting all its messages; ensure the thread id is valid.
add_label_idsarrayremove_label_idsarraythread_idstringuser_idstringGMAIL_MOVE_TO_TRASHMoves an existing, non-deleted email message to the trash for the specified user.2 params
Moves an existing, non-deleted email message to the trash for the specified user.
message_idstringuser_idstringGMAIL_PATCH_LABELPatches the specified label.6 params
Patches the specified label.
colorobjectidstringlabelListVisibilitystringmessageListVisibilitystringnamestringuserIdstringGMAIL_REMOVE_LABELPermanently deletes a specific, existing user-created gmail label by its id for a user; cannot delete system labels.2 params
Permanently deletes a specific, existing user-created gmail label by its id for a user; cannot delete system labels.
label_idstringuser_idstringGMAIL_REPLY_TO_THREADSends a reply within a specific gmail thread using the original thread's subject, requiring a valid `thread id` and correctly formatted email addresses. supports attachments via the `attachment` parameter with valid `s3key`, `mimetype`, and `name`.9 params
Sends a reply within a specific gmail thread using the original thread's subject, requiring a valid `thread id` and correctly formatted email addresses. supports attachments via the `attachment` parameter with valid `s3key`, `mimetype`, and `name`.
attachmentobjectbccarrayccarrayextra_recipientsarrayis_htmlbooleanmessage_bodystringrecipient_emailstringthread_idstringuser_idstringConfiguration
GMAIL_OAUTH_CLIENT_IDsecretOAuth2 client ID from Google Cloud Console (for personal Gmail accounts).
GMAIL_OAUTH_CLIENT_SECRETsecretOAuth2 client secret from Google Cloud Console.
GMAIL_OAUTH_REFRESH_TOKENsecretRefresh token from the OAuth2 setup script.
GMAIL_SERVICE_ACCOUNT_CLIENT_EMAILService account email address (for Google Workspace).
GMAIL_SERVICE_ACCOUNT_PRIVATE_KEYsecretService account private key in PEM format (for Google Workspace).
GMAIL_IMPERSONATE_EMAILEmail address to impersonate (required for service account mode).
GMAIL_ENABLED_TOOLGROUPSComma-separated list of tool groups to enable (readonly, readwrite, readwrite_external).
Readme
PulseMCP's MCP Servers
We build reliable servers thoughtfully designed for MCP Client-powered workflows.
Design principles
You can have confidence that any Pulse-branded MCP server was built with these north stars in mind:
Details
- Repository
- github.com/pulsemcp/mcp-servers
- Categories
- Email & Messaging, Productivity & Notes
- Package
gmail-workspace-mcp-server- Transport
- STDIO
- Auth
- Required
- Registry
- MCP registry, active
Questions
What can an agent do with the Gmail MCP server?
The Gmail server gives an agent 20 tools for working with Gmail, including sending replies within a thread, creating email drafts, fetching and listing emails and threads, and managing labels. It also lets the agent move messages to the trash, retrieve attachments, and read contacts and the Gmail profile.
Does the Gmail MCP server work with personal and Workspace accounts?
Yes, the server supports OAuth2 for personal Gmail accounts and a service account for Google Workspace accounts. Setup needs environment variables such as GMAIL_OAUTH_CLIENT_ID and GMAIL_OAUTH_REFRESH_TOKEN for OAuth2, or GMAIL_SERVICE_ACCOUNT_CLIENT_EMAIL and GMAIL_SERVICE_ACCOUNT_PRIVATE_KEY for a service account.
Where does the Gmail MCP server rank in its category?
The Gmail server sits in the top 25 of the Email and Messaging category on Claude Marketplaces. It covers Gmail specifically, with tools for drafts, threads, labels and attachments in one server.
Which environment variables does the Gmail MCP server need?
The server reads GMAIL_OAUTH_CLIENT_ID, GMAIL_OAUTH_CLIENT_SECRET, GMAIL_OAUTH_REFRESH_TOKEN, GMAIL_SERVICE_ACCOUNT_CLIENT_EMAIL, GMAIL_SERVICE_ACCOUNT_PRIVATE_KEY, GMAIL_IMPERSONATE_EMAIL and GMAIL_ENABLED_TOOLGROUPS. It runs over stdio and is published as the npm package gmail-workspace-mcp-server.
More from pulsemcp
All 5Similar to Gmail
More Email & MessagingFaithk7 Gmail Mcpfaithk7Full read and write access to Gmail: messages, threads, labels, drafts, and mailbox settings.
Multi Gmail Mcpgx-5519 starsGives Claude access to multiple Gmail accounts: search, read, send, reply, draft, and label.
Email Mcpcodefuturist169 starsGives AI assistants full IMAP/SMTP email access across multiple accounts: read, search, send, and manage.
Google Workspaceaaronsb200 starsUnified Gmail, Calendar, Drive, Docs, Sheets, Tasks, Meet, and Contacts access across multiple Google accounts.