عربي
News
●E-invoicing: the last date to connect for wave 25 is February 1, 2027●WhatsApp Business: service messages are paid after 1,000 free per month●Salla acquires Paylink to strengthen payment solutions for merchants●Google launches a Gemini agent for businesses first, then consumers●Hostinger's White Friday deals continue until December 14

Get an automatic email for every new Google Forms submission

Link a Google Forms form to a Google Sheets spreadsheet, then add a short script that emails you the content of every new response as soon as it arrives.

The problem

You publish a form for customer orders or appointment bookings, and responses land in a spreadsheet you only open a day later. The customer waits, and you don't know there is a new request. What you want is an email the moment the form is submitted, with the customer's name and request details, without paying for an outside tool.

The tool

We use Google Forms, Google Sheets and Google Apps Script, all from Google. According to the official docs, a form can be linked to a spreadsheet that stores its responses. A script bound to the spreadsheet can then run automatically when the form is submitted, through a Form submit trigger. The script sends the email with the MailApp service. You only need a Google account, and no coding skill beyond copying an eight-line script.

The steps

  1. Open the form in Google Forms, go to the Responses tab, then Summary.
  2. Click More at the top and choose Select destination for responses. Choose Create a new spreadsheet or Select existing spreadsheet, then Create or Select. From now on every new response is saved in a spreadsheet.
  3. Open the spreadsheet, then from the menu choose Extensions then Apps Script. This creates a script bound to your spreadsheet.
  4. Delete the existing code and paste the following code, replacing the address with your own email:
function onFormSubmit(e) {
  const v = e.namedValues;
  const lines = Object.keys(v).map(k => k + ': ' + v[k].join(' / '));
  MailApp.sendEmail('you@example.com', 'New form response', lines.join('\n'));
}
  1. Click Save. According to the docs, the namedValues object maps each form question to an array of its answers, so the email will contain one line per question: its title and the answer.
  2. From the left menu click Triggers, then Add Trigger at the bottom right. Choose the function onFormSubmit, the event source as the spreadsheet, and the event type Form submit, then Save.
  3. A permissions window will appear the first time. Approve it with the same Google account that will send the email. The docs note that triggers run under the account of whoever created them.
  4. Test it by filling in the form yourself from its public link. A note from the docs: submitting a response from inside a script does not fire the trigger, so fill the form by hand like any customer.
  5. Check that the email arrives, and open the spreadsheet to confirm the response appears there. If no email arrives, go back to steps 4 and 6 and check the address and that the trigger was created.
  6. To notify more than one person, write the addresses in the first argument separated by commas, as the MailApp.sendEmail description in the docs says.

The real cost

Nothing on a free account. But email has a daily limit according to the official quotas page: 100 recipients per day for free accounts (gmail.com) and 1,500 recipients per day for Google Workspace accounts. The quota counts recipients, not messages, so one message to three people uses 3. Triggers also have a daily runtime limit: 90 minutes for free accounts and 6 hours for Workspace, which is far more than a script like this needs. Check the numbers on the official page, as they may change.

The free alternative

If you don't want to write a script, use a ready-made automation tool with visual steps, but check its free-plan limits on its official pricing page. For very low volume, simply opening the spreadsheet by hand twice a day is enough.

Notes

  • We have not tried these steps ourselves yet; they are based on the current official docs. Button names may change, so if your interface differs, follow the docs.
  • The trigger runs as your account, and the email goes out from your account. Don't put passwords or keys in the code.
  • Be careful when renaming form questions, because that changes the column titles that appear in the email.
  • The form collects customer data, so handle it according to the privacy rules in your country, and share the spreadsheet only with people who need it.

Sources

  1. support.google.com
  2. developers.google.com
  3. developers.google.com
  4. developers.google.com
  5. developers.google.com

Did you like this guide?

The weekly newsletter is being prepared. Leave your email and we'll send it when it launches.

We use your email only to send the newsletter. Privacy policy