What is Mail Merge In Google Workspace and how to do a mail merge in Google Workspace?

Mail Merge

 



Mail merge is a feature in Google Workspace that allows you to send personalized emails or letters to multiple recipients. It's a great way to save time and effort when sending mass communications.


Steps to do a mail merge in Google Workspace:-


 :- Click the following button to make a copy of the Gmail/Sheets Mail Merge sample spreadsheet. The Apps Script project for this solution is attached to the spreadsheet.
Make a copy


:- In your copied spreadsheet, update the Recipients column with email addresses you want to use in the mail merge.


:- (Optional) Add, edit, or remove columns to customize the data you want to include in your email template.


If you change the name of the Recipient or Email Sent columns, you must update the corresponding code in the Apps Script project. You can open the Apps Script project from the spreadsheet by clicking Extensions > Apps Script.

Create an email template

:- In your Gmail account, create an email draft. To include data from the spreadsheet in your email, use placeholders that correspond to column names surrounded by curly braces, such as .

  • If you format the text in the email, you must also format the placeholder brackets.
  • Placeholders are case sensitive and must exactly match the column headers.

:- Copy the subject line of your email draft.

Run the script

:- In the spreadsheet, click Mail Merge > Send Emails. You might need to refresh the page for this custom menu to appear.


:- When prompted, authorize the script. If the OAuth consent screen displays the warning, This app isn't verified, continue by selecting Advanced > Go to {Project Name} (unsafe).



:- Click Mail Merge > Send Emails again.






:- Paste the email template subject line and click OK.

If you applied a filter to the sheet, the script still emails the filtered participants, but it won't add the timestamp.



Please find the below support article for your reference:- 

https://developers.google.com/apps-script/samples/automations/mail-merge