Send Personalized Tweets & DMs in Bulk from a Google Spreadsheet

Introducing Twitter Merge, a new Twitter app that will help you send personalized tweets and direct messages (or DMs) to multiple Twitter users in one-go. You create a template for the tweet, specify a list of Twitter users and the app will take care of the rest. The Twitter Merge app, like Gmail Mail Merge, also runs inside a Google Spreadsheet but instead of emails, this one allows you to send customized tweets and DMs in bulk.

Let me share a scenario where such an app may be useful.

Say you are a brand and you are trying to organize meetings with Twitter users in various cities on different dates. You want to send them invites on Twitter but it would take just too much effort to compose the tweets or DMs manually. You thus create an invite template and add the Twitter user names in a Google Sheet. The Twitter Merge app, using that template, will send a personalized tweet (or DM) to every handle listed in the sheet automatically.

Here’s a sample Tweet template and the corresponding tweets / DMs generated from the template.

Personlized Tweets

To create a Twitter template, write a tweet in notepad (or any text editor) and replace the words that will be different in each tweet with {{variables}}. For instance, if you are write a tweet with customized name and city, your template will read something like hello _{{first name}}_ from _{{city name}}_ while the “First Name” and “City Name” will be columns in your Google Spreadsheet.

Bulk Send Tweets & Direct Messages

Follow these steps to get started:

  1. Click here to copy the Twitter Merge spreadsheet in your Google Drive.
  2. Add new columns to the sheet so that you have one for every variable that exists in your tweet template. The column names should be the same as the variable name though the case doesn’t matter.
  3. Fill the spreadsheet with one or more rows. Add the Twitter screen names in the “Twitter User” column while keeping the “Tweet” and “Status” columns as blank.
  4. Go to the Twitter Merge menu at the top and choose Authorize. This is required because you need to allow the Spreadsheet to send tweets on our behalf.
  5. From the same menu, choose Configure and paste the text of your tweet template. You also need to specify whether the tweets are be sent as DMs or public tweets. Save the configuration.

We are almost done now.

The “Tweet” column will display the actual text that will be sent and you have an option to manually edit that text. Choose Send tweets from the Twitter menu and the app will send the customized tweets to all the listed Twitter users. The following video (link) will also guide you through the process.

Also see: Archive Twitter Search Results in Google sheets.

Later, if you wish to send more tweets or DMs, you can just repeat from step 2 onwards.  Also, if the “Status” column for a tweet is set as “SENT”, the app will skip sending a tweet to that particular Twitter user.

Internally, there’s a Google Script running that transforms your template into actual tweets using data from the row and it then connects to the Twitter API to send the tweets. Give it a try and do share your feedback in the comments section below.

Amit Agarwal

Amit Agarwal

Google Developer Expert, Google Cloud Champion

Amit Agarwal is a Google Developer Expert in Google Workspace and Google Apps Script. He holds an engineering degree in Computer Science (I.I.T.) and is the first professional blogger in India.

Amit has developed several popular Google add-ons including Mail Merge for Gmail and Document Studio. Read more on Lifehacker and YourStory

Awards & Titles

Digital Inspiration has won several awards since it's launch in 2004.

Google Developer Expert

Google Developer Expert

Google awarded us the Google Developer Expert award recogizing our work in Google Workspace.

ProductHunt Golden Kitty

ProductHunt Golden Kitty

Our Gmail tool won the Lifehack of the Year award at ProductHunt Golden Kitty Awards in 2017.

Microsoft MVP Alumni

Microsoft MVP Alumni

Microsoft awarded us the Most Valuable Professional (MVP) title for 5 years in a row.

Google Cloud Champion

Google Cloud Champion

Google awarded us the Champion Innovator title recognizing our technical skill and expertise.

Email Newsletter

Sign up for our email newsletter to stay up to date.

We will never send any spam emails. Promise.