How to Send an Email With a Click in Google Sheets

Learn how to send an email directly from Google Sheets with just a click using Google Apps Script. This tutorial walks you through creating a simple email function that utilizes your spreadsheet data.

I wanna send an email to anyone that I have selected here. So I have someone's name, someone's email address, and I'm on the row and I just wanna send them an email, uh, form email, maybe everything's gonna be okay. Let's do that with an image here in a one first. I wanna get that image . Let's get see if this one works. Save image , send email. I'll go and insert it as an image . Oversells. Okay, I'm gonna need compressor to com. Change it to a PNG. There we go. So now I need to create a script that goes here with assigned script. Go up to Extensions app script . Let's create a function called email. We're gonna need the rower on, which is gonna be spreadsheet , app.gi, active range , get row,

and our email is going to be. Spreadsheet app. Do get active sheet . Do get range , row and column. Which column is it in? It is in column C, so that's number three. Get value. We have a name here as well in the second column, or column B, so we can get that as well. And we need to send an email. I'm gonna use Gmail app for this. Send email. We need who it's to. That's email. We need the subject. It'll be okay. And we need the body. Hey, space. Then plus name plus, and then we're gonna use slash n slash n for new line. Everything's gonna be okay.

Come in. S. Our function is called email, and we're gonna go over here and click the three dots. Assign Script, email, click. Okay. We're gonna have to authorize probably the first time we do this. Let's go to C two or anywhere on that row and click. And here's the email that I sent to another email address and I said, Hey, Andy, everything's gonna be okay. Done. That was pretty cool, right? Just send an email with a click. You are watching better sheets here on YouTube. Make sure you check out this video or this video and subscribe right now to get more tips, tricks, how tos, get more out of your Google sheets than you ever have before. I'm excited to be making a ton more videos here. Ask me questions down in the comments and I will answer them in future videos.

But for right now, right here, one of these videos is gonna be your next Google sheet.