Gmail and Google Sheets are both part of Google Workspace, but they don’t share data on their own. “Connecting” them means one of two jobs: getting data out of your emails and into a sheet, or using a sheet to send, share or track email. This guide covers both directions, the methods for each (built-in features, Google Apps Script and add-ons), and links every detailed guide we have on the topic.
Which direction do you need?
| What you want to do | Direction | Best starting point |
|---|---|---|
| Log order, payment, lead or booking emails as rows in a sheet | Gmail → Sheets | An email parser add-on, or Apps Script if you want to code it |
| Update a sheet automatically when new emails arrive | Gmail → Sheets | A scheduled import (add-on) or a time-driven Apps Script trigger |
| Send a spreadsheet to someone | Sheets → Gmail | Gmail’s built-in sharing and “Email as attachment” |
| Send personalised emails to a list in a sheet | Sheets → Gmail | Apps Script or a mail-merge add-on |
| Track whether your emails are opened | Sheets → Gmail | A tracking pixel that logs to a sheet |
| Route, answer or archive emails before they reach a sheet | Inside Gmail | Gmail filters, auto-reply and backups |
Gmail to Google Sheets: getting email data into a spreadsheet
This is the direction most people mean when they search for a “Gmail Google Sheets integration”: many similar emails, such as order confirmations, payment notices or form submissions, turned into one row per email and one column per field.
There are three ways to do it:
- Copy and paste. Fine for a handful of emails, slow and error-prone for hundreds.
- Write an Apps Script. A script can search Gmail and write to a sheet (an example is below), but you build and maintain the parsing yourself, and it breaks when an email’s layout changes.
- Use an email parser add-on. You describe once which emails to read and which text to pull out, and the add-on fills the sheet, in bulk or on a schedule.
How xtractor.app connects Gmail to Google Sheets
xtractor.app is a Google Workspace add-on that runs inside Google Sheets and reads emails from your Gmail account:
- Find the emails. Search Gmail by subject, sender, date and content.
- Define what to extract. Custom filters, including text-before/text-after rules and regex filters, pick out each value. xtractor.app can also use AI to parse emails, alongside the filters you define. Multiple parsing contexts let one search handle emails whose format varies.
- Import. Import thousands of emails in one bulk import, then let imports run automatically on a schedule, daily or more often. Save your searches and filters to reuse them.
The data lands in Google Sheets as rows and columns. From there you can download it as Excel or CSV. Extracted email data stays in your own Google Sheet; xtractor.app does not store it in its own database.
Know the limits before you set it up: xtractor.app works with Gmail only (no Outlook, Microsoft 365, Exchange or IMAP mailboxes), it extracts from the email text rather than attachments such as PDFs (custom attachment parsing is available on request), and it has no Zapier or Make integration, public API or webhooks.
The full walkthrough is in Email to Google Sheets: How to Import Email Data Automatically, and the no-code basics are in Gmail to Google Sheets Automatically: The Beginner’s Guide. For a broader look at Gmail and Sheets working together, see Unlock the Power of Data: Integrating Google Sheets with Gmail.
Sending only the right emails
If you forward a subset of your mail to another address or tool, Gmail filters decide which messages go. Using Gmail Filters for Selective Auto-Forwarding shows how to forward only specific senders or subjects.
Google Sheets to Gmail: sending, sharing and tracking
Share or attach a spreadsheet
To send someone a sheet you don’t need any integration: share a link, export the sheet as a file and attach it, or use the “Email as attachment” option in Google Sheets. Step-by-step instructions are in Attaching Google Sheets to Emails: Quick and Easy Methods. For Excel files, see How to Email an Excel Sheet: A Step-by-Step Guide.
Send emails from a sheet
To email a list of people from spreadsheet rows, use Apps Script (below) or a mail-merge add-on from the Google Workspace Marketplace, such as Yet Another Mail Merge, Mailmeteor or GMass. These are separate products from xtractor.app. Automating Emails from Google Sheets: A Comprehensive Guide covers personalised sends, templates and scheduling.
Track opens
Email Open Tracking: Build Your Own Pixel System with Gmail and Google Sheets shows how to log email opens to a sheet with a small Apps Script web app.
Connecting Gmail and Google Sheets with Apps Script
Apps Script is Google’s built-in scripting tool, and it can work in both directions. Open your sheet and choose Extensions → Apps Script to start.
Sheets to Gmail: send one email per row. With email addresses in column A, subjects in column B and messages in column C:
function sendEmailFromSpreadsheet() {
var sheet = SpreadsheetApp.getActiveSheet();
var data = sheet.getRange("A2:C" + sheet.getLastRow()).getValues();
data.forEach(function (row) {
var emailAddress = row[0];
var subject = row[1];
var message = row[2];
if (emailAddress) {
MailApp.sendEmail(emailAddress, subject, message);
}
});
}
Gmail to Sheets: log matching emails as rows. This writes the date, sender and subject of recent emails matching a Gmail search:
function logEmailsToSheet() {
var sheet = SpreadsheetApp.getActiveSheet();
var threads = GmailApp.search('subject:"order confirmation" newer_than:7d');
threads.forEach(function (thread) {
thread.getMessages().forEach(function (message) {
sheet.appendRow([message.getDate(), message.getFrom(), message.getSubject()]);
});
});
}
Pulling specific values out of the email body (an amount, an order number) means adding your own text matching to this script, and re-running it on a schedule means deduplicating rows yourself. That upkeep is the main reason people switch to an add-on.
Run it automatically. In the Apps Script editor, open Triggers, click Add Trigger, choose the function, and pick a time-driven schedule.
Add a menu. A custom menu lets anyone run the script from the sheet:
function onOpen() {
SpreadsheetApp.getUi()
.createMenu('Email Tools')
.addItem('Send Emails', 'sendEmailFromSpreadsheet')
.addItem('Log Emails', 'logEmailsToSheet')
.addToUi();
}
For more control over message formatting and labels, the Gmail API is available to Apps Script as an advanced service.
Troubleshooting scripts
- Quotas. Apps Script limits how many recipients a script can email per day, with a lower limit for personal Google accounts than for Workspace accounts. Check Google’s current quotas before a large send.
- Authorization errors. The first run asks for permission to access Gmail and Sheets; re-run the function from the editor to grant it.
- Timeouts. A single run has a time limit. Process emails in batches and let a time-driven trigger pick up where the last run stopped.
- Duplicates. A script that re-reads the same search adds the same emails again. Store the message ID in a column and skip IDs you have already logged.
Managing your Gmail around the integration
These guides cover the Gmail side of the workflow: automating replies and routing, and keeping your inbox under its storage limit.
- Automating Email Tasks in Gmail: Beyond Auto-Forwarding
- Setting Up Gmail Auto-Reply: A Step-by-Step Guide
- Gmail Email Backup: Safeguarding Your Digital Communication
- If Your Gmail Inbox Is Full, Here’s How You Can Get Back 15GB of Free Storage
- Gmail Storage Full? Unlock Unlimited Space with This Simple Trick
Related guides
- Choosing a tool: Free Email Parser: 6 Free Tools Compared and How to Choose
- Excel instead of Sheets: How to Extract Data from Gmail to Excel and How to Export Gmail Emails to CSV
- Order and payment emails: Extract Order Numbers and Amounts From Emails Into Sheets
- Writing your own parser in code: Python Email Parser
Frequently asked questions
Can Gmail and Google Sheets be connected without coding?
Yes. For sending, Google Sheets can email a sheet as an attachment, and mail-merge add-ons send from rows. For importing email data, an email parser add-on such as xtractor.app runs inside Google Sheets: you search your Gmail, choose what to extract, and import.
Can a Google Sheet update automatically from new emails?
Yes, with a scheduled import. xtractor.app imports can run on a schedule, daily or more often. With Apps Script, a time-driven trigger re-runs your script.
Can I connect Outlook to Google Sheets the same way?
Not with xtractor.app, which works with Gmail only. The Apps Script examples above are also Gmail-only.
Can I get the email data as Excel or CSV?
Yes. Data imported with xtractor.app lands in Google Sheets, and you can download it from there as Excel or CSV.
Does xtractor.app send emails from my sheet?
No. xtractor.app reads emails from Gmail into Google Sheets. To send emails from a sheet, use Apps Script or a mail-merge add-on.
Is my email data safe?
Extracted data stays in your own Google Sheet; xtractor.app does not store it in its own database. xtractor.app is CASA Tier 2 certified, an independent security assessment Google requires for apps that access sensitive data.
How much does xtractor.app cost?
It is free to install and offers a free trial. Paid plans run from $5 to $40 a month billed annually, or $24 to $129 a month billed monthly, and custom plans and bulk pricing are available on request.
Connect your Gmail to Google Sheets
Install xtractor.app free from the Google Workspace Marketplace, search your Gmail, and see your emails as rows in Google Sheets.