How to Monitor your Website's Uptime with Google Sheets

Published in: Google Analytics - Google Docs

Would you like to receive instant email alerts as soon as your website goes down or is inaccessible to users? Most website monitoring services follow the “freemium” model - they have free plans for basic downtime and uptime monitoring of a website but you need to pay for unlimited email or SMS alerts. You may also need to upgrade to monitor multiple websites. There’s a good alternate though.

Website uptime monitor

Make your own Website Uptime Monitor with Google Sheets and Gmail

You can create your own website monitor that runs on Google servers and sends email alerts via Gmail when your website goes down or is back up and accessible again. The website monitor logs all events in a Google Spreadsheet or you can even choose to record store the uptime and downtime activity inside Google Analytics.

How to Setup Website Monitor

Here’s how you quickly configure Google Sheets to monitor the uptime /downtime of any public website. The setup has to be done just once and the Google Apps Script attached to the Google Spreadsheet will continuously monitor your sites in the background.

Let’s get started:

  1. Click here to copy the website monitoring Google sheet into your Google Drive.
  2. Go to the Website Monitor menu (near Help) and choose Configure. You may have to authorize the script the first time you configure the monitor.
  3. Specify your website URL and the email address where you wish to be notified. You can put multiple addresses separated by commas.
  4. This is option. Enter the Google Analytics Id (e.g., UA-123456-78) and the site monitor will log downtime / uptime events in  your Analytics account.

Click the Start button and the Google sheet will start monitoring your website in the background. You may now close the sheet.

The uptime and downtime times are logged in theGoogle Spreadsheet so you can use that data to analyze the performance of your web hosting company.

How to Monitor Multiple Websites?

The website monitor is open-source (Github) under MIT License. You can check our Google Apps Script page to discover more interesting projects made with Google Scripts.

If you would like to monitor more than one website with app, make a copy of the same Google Sheet and specify another website URL in the sheet.

How Website Monitor works?

Internally, a Google Script attached to the Google Sheet is doing the monitoring and logging events in Google Sheets and Google Analytics.

The script triggers every few minutes and then tries to fetch your website using URLFetchApp, a Google service similar to wget or curl. If the HTTP response code is anything other than 200, it indicates that there’s an issue with your website and an email alert is sent via the Gmail API.

A previous version of the script had the ability to send SMS text messages when your website goes down. The functionality is now removed since Google no longer support text alert notifications inside Google Calendar.

📮  Subscribe to our Email Newsletter for Google tips and tutorials!
Published in: Google Analytics - Google Docs

Looking for something? Find here!

Meet the Author

Web Geek, Google Developer Expert
Amit Agarwal

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. He is the developer of Mail Merge for Gmail and Document Studio. Read more on Lifehacker and YourStory

Get in touch

Google Add-ons

Do more with your Gmail and GSuite account

We build bespoke solutions that use the capabilities and the features of Google Workspace for automating business processes and driving work productivity.

  1. Mail Merge with Attachments
    Send personalized email to your Google Contact with a Google Sheet and Gmail
  2. Save Emails and Attachments
    Download email messages and file attachments from Gmail to your Google Drive
  3. Google Forms Email Notifications
    Send email notifications to multiple people when a new Google Form is submitted
  4. Document Studio
    Create beautiful pixel perfect documents merging data from Google Sheets and Google Forms
  5. Creator Studio for Google Slides
    Turn your Google Slides presentations into animated GIFs and videos for uploading to YouTube