Gmail Add-ons

The purpose of many emails is to get the recipient to do a specific task or reach a goal, such as adding a calendar event, filling out a form, making a reservation, or using other applications. However, recipients then have to complete the task without any further prompting, often doing a number of manual steps.

You can save time and effort for your users by automating these tasks with Gmail add-ons. When a user reads a message in Gmail, a Gmail add-on can present a interactive, customized message UI that lets the user act on the message in various ways, such as by:

  • Displaying additional information for the user in the Gmail UI.
  • Connecting to non-Google services, to retrieve information or take other actions.
  • Providing the means to control the add-on behavior or send information to another service.

In addition to the message UI, a Gmail add-on can define an interactive, customized compose-time UI that can assist the user when they are composing or replying to messages.

Gmail add-ons are developed using Apps Script, a scripting language based on JavaScript that serves as a connective platform between Google products like Docs, Sheets, Drive, and Gmail. Every Gmail add-on has a corresponding Apps Script project where you define your add-on's appearance and behavior.

The video above shows how you can build an add-on to import receipt information directly from Gmail into a Google Sheet to help your users process their expense reports from one place.

Once you've created an add-on, you can publish it for your domain or globally for others to use.

Structure of a Gmail add-on

Example add-on card

Gmail add-ons present information and widgets to the user in the sidebar of the Gmail UI. An add-on consists of a main identifying toolbar along with one or more contextual cards. You can define navigation flows between cards for a rich interaction experience.

Each card consists of a header and one or more card sections. Each section is composed of a set of widgets. Widgets display information to the user or provide interaction controls like buttons.

The contextual cards you create for your add-ons work for both web and mobile versions of Gmail. This means that you don't need to create separate web and mobile versions of the add-on—the same code works everywhere!

See what you can make

You build Gmail add-ons using Apps Script, a server-side scripting platform that requires zero setup and can connect to many Google services, including Calendar, Drive, Docs, Sheets, Forms, and of course, Gmail.