IntegrationsBeginner

How to connect Gmail to ChatGPT so it drafts replies for you

Wire incoming Gmail messages into ChatGPT through Zapier so every new email gets an AI-written draft reply waiting in your inbox.

9 minBeginner

If you spend an hour a day replying to email, the fastest win is letting an AI write the first draft. This guide connects Gmail to ChatGPT through Zapier. When a new email lands, Zapier sends the body to ChatGPT, ChatGPT writes a reply, and the reply is saved as a Gmail draft you can edit and send. Nothing goes out without you approving it.

  • A Gmail account
  • A free or paid Zapier account
  • An OpenAI API key from platform.openai.com
  • About 10 minutes

Step 1: Create a new Zap and pick the Gmail trigger

In Zapier, click Create then Zap. For the trigger app choose Gmail and the event New Email Matching Search. This is better than New Email because you can filter to only the messages you want AI to handle, for example unread mail in your inbox.

Zapier - Choose trigger
Trigger app: Gmail
Event: New Email Matching Search
Search: in:inbox is:unread -from:me
Account: you@gmail.com (connected)
Gmail New Email Matching Search keeps the trigger focused.
Use a tight search
A search like in:inbox is:unread -from:me -category:promotions stops the Zap firing on newsletters and your own sent mail, which saves both your time and your API budget.

Step 2: Add a ChatGPT action to write the draft

Add an action step and choose the OpenAI (ChatGPT) app, then the event Conversation. Connect it with your OpenAI API key when prompted. In the User Message field, write a clear instruction and insert the email body from the Gmail trigger using the field picker.

User Message field
You are my email assistant. Write a polite, concise reply to the email below.
Keep my tone friendly and direct. Do not invent facts or commitments.
End with "Best, Alex".

--- EMAIL ---
From: {{1.From}}
Subject: {{1.Subject}}
Body:
{{1.Body Plain}}
Pick a cheap model
In the OpenAI action set the model to gpt-5-mini or gpt-5.1-mini for drafting. They are fast and inexpensive, and reply quality for short emails is more than enough.

Step 3: Save the reply as a Gmail draft

Add a second action: Gmail, event Create Draft Reply. Map the Thread or Message ID from the trigger so the draft attaches to the original conversation, and map the Body to the ChatGPT output from step 2. This keeps everything threaded and never auto-sends.

Zapier - Create Draft Reply
Action: Gmail / Create Draft Reply
Thread: {{1.Thread ID}}
To: {{1.From}}
Body: {{2.Reply}} <- ChatGPT output
[ Test step ] -> Draft created in Gmail
Map the AI output into the draft body, attached to the thread.

Step 4: Test and turn it on

Click Test on each step, then send yourself a sample email that matches your search. Open Gmail and check the Drafts folder. When the draft looks right, flip the Zap to On. From now on, matching emails get an AI draft within a minute or two.

Result: a colleague emails asking to move a meeting. A minute later you open Gmail and a threaded draft is already there saying you can do Thursday at 2pm instead. You tweak one line and hit send. The whole reply took ten seconds.

Watch related tutorials

Tags
#gmail#chatgpt#zapier#email