Skip to content
Home

/

Glossary

/

Integration

/

Google Apps Script

Integration

6 min read

Also: Apps Script, GAS, script.google.com, Google Sheets script, Google Apps Script triggers, Extensions > Apps Script

Google Apps Script

Quick answer

Google Apps Script is Google's cloud-hosted JavaScript platform for automating Sheets, Gmail, Drive, Docs, Calendar and Forms, run from Extensions > Apps Script and fired by triggers such as onEdit or a time-driven schedule. Each run stops after 6 minutes and daily quotas apply; if you hit them, see Apps Script quotas and limits.

Google Apps Script is Google's cloud-hosted JavaScript platform for automating Google Workspace: Sheets, Gmail, Drive, Docs, Calendar and Forms. Scripts run on Google's servers, can be triggered on a schedule or by events, and are limited by daily quotas such as a 6-minute cap per execution.

Last verified

What people do with Google Apps Script

Key facts

Made byGoogle
LanguageJavaScript on the V8 runtime (the legacy Rhino runtime stopped executing after 31 January 2026)
CostNo separate charge; included with a Google account, subject to daily quotas
Max runtime per execution6 minutes (consumer and Google Workspace accounts)
Trigger total runtime90 minutes/day (consumer) vs 6 hours/day (Google Workspace)
URL Fetch calls20,000/day (consumer) vs 100,000/day (Google Workspace)

What is Google Apps Script?

Google Apps Script is a scripting platform made by Google that lets you write JavaScript to automate and extend Google Workspace apps. You open it from a spreadsheet with Extensions > Apps Script, or directly at script.google.com, write a function, and run it on Google's servers. There is nothing to install and no separate bill: it comes with a Google account, and what you can do is bounded by daily quotas rather than a price.

Apps Script is how many people take their first step past formulas. A function can read a range from Sheets, send a Gmail message for each row, create a Drive folder, add a Calendar event or fetch data from an external API, all with built-in services like SpreadsheetApp, GmailApp, DriveApp and UrlFetchApp that handle authentication for you.

How it works

  • Bound and standalone scripts. A bound script lives inside a Sheet, Doc or Form and can add custom menus and custom functions to it. A standalone script lives in Drive on its own.
  • The V8 runtime. Scripts run modern JavaScript on V8. Google deprecated the older Rhino runtime in February 2025, and scripts still on Rhino stopped executing after 31 January 2026, so any old script that suddenly broke this year is worth checking for that first.
  • Triggers. Simple triggers such as onEdit and onOpen fire on document events. Installable triggers can run a function on a time schedule (every few minutes, hourly, daily, weekly) or when a form is submitted. Google may randomize the exact minute a time-driven trigger fires, so do not rely on precise timing.
  • Authorization. The first run asks the user to grant OAuth scopes, for example permission to send email as you. Scripts run as the user who authorized them.
  • Deployments. A script can be published as a web app (with doGet and doPost handlers that receive HTTP requests), an API executable, or a Workspace add-on. Developers who prefer local editing and version control use clasp, Google's command-line tool for Apps Script projects.
  • What people use Apps Script for

  • Sending templated emails or reminders from rows in a sheet.
  • Refreshing IMPORTXML or IMPORTHTML data on a fixed schedule with a time-driven trigger.
  • Pulling data from a REST API into Sheets with UrlFetchApp, a common way to build a small API integration without a server.
  • Receiving webhooks through a web app's doPost and appending them to a sheet.
  • Generating Docs or PDFs from a template and filing them in Drive.
  • Quotas and common problems

    Apps Script's limits are the reason most projects outgrow it. The official quotas page lists, among others, a 6-minute maximum runtime per execution for both consumer and Workspace accounts, 90 minutes per day of total trigger runtime on consumer accounts (6 hours on Workspace), and 20,000 URL Fetch calls per day on consumer accounts (100,000 on Workspace). Quotas reset 24 hours after the first request, and Google can change them.

    The errors people search for most map directly onto those limits:

  • Exceeded maximum execution time. The run passed six minutes. The usual fix is to process in batches, save progress (for example in PropertiesService) and resume from a trigger.
  • Service invoked too many times for one day. A daily quota, often URL Fetch or email, is used up. Cache responses and batch work.
  • Authorization is required to perform that action. The script needs scopes the user has not granted, often after the code changed. Run it manually once to re-authorize.
  • Slow Sheets access. Calling getValue() and setValue() cell by cell is slow; read and write whole ranges with getValues() and setValues().
  • UrlFetchApp sees no JavaScript content. Like IMPORTXML, it downloads raw HTML from Google's servers. It cannot render a page, click, or sign in to a site through a browser.
  • Apps Script and automation

    Apps Script is the right tool when the work lives inside Google Workspace and fits in a few minutes per run. It becomes awkward when a job needs a real browser, runs longer than six minutes, has to call many external services, or needs a person to watch and step in. At that point teams typically move scheduling to a cron-style scheduler, talk to Sheets through the Google Sheets API, and use a browser automation tool for sites that have no API. The Google Sheets automation guide compares these routes.

    Autonoly covers the parts Apps Script cannot. Its agent and workflows drive a real Chromium browser, so they can work with JavaScript-heavy sites, and they write results to Sheets, Gmail, Drive and Docs through native Google integrations. Scheduled workflows run on a cron schedule with a timezone. It is not a replacement for Apps Script's in-document features such as custom menus, onEdit triggers or custom spreadsheet functions.

    Why It Matters

    Apps Script is the default automation layer for anyone who lives in Google Sheets and Gmail, and its quotas (6 minutes per run, daily trigger and URL Fetch caps) define where spreadsheet automation stops working. Knowing them helps you decide whether to fix a script or move the job elsewhere.

    How Autonoly Solves It

    Autonoly handles the work Apps Script is not built for: driving a real Chromium browser on JavaScript-heavy sites, longer multi-step jobs, and runs you can watch and take over. Workflows write to Google Sheets, Gmail, Drive and Docs through native integrations and run on a cron schedule. In-document features such as custom menus and onEdit triggers remain Apps Script's job.

    Learn more

    Examples

    • A time-driven trigger that runs every morning, reads new rows from a sheet and sends a Gmail reminder for each overdue invoice

    • A web app doPost handler that receives a webhook from a form tool and appends each submission to a Google Sheet

    • Splitting a 20-minute import job into batches that save their position in PropertiesService so each run finishes under the 6-minute limit

    Frequently Asked Questions

    There is no separate charge. Apps Script is included with consumer Google accounts and Google Workspace. What you can do is limited by daily quotas, such as total trigger runtime, URL Fetch calls and email recipients, which are higher on Workspace accounts.

    Google's quotas page lists 6 minutes per execution for both consumer and Workspace accounts. A run that goes longer stops with 'Exceeded maximum execution time'. Long jobs need to be split into batches that save progress and resume from a trigger.

    A daily quota for one service is used up, commonly URL Fetch (20,000 calls a day on consumer accounts, 100,000 on Workspace) or email. Quotas reset 24 hours after the first request. Cache responses, batch requests and avoid fetching inside tight loops.

    One likely cause: Google deprecated the Rhino runtime in February 2025 and scripts still on Rhino stopped executing after 31 January 2026. Open the project settings and enable the V8 runtime, then fix any syntax V8 rejects.

    Partly. UrlFetchApp can download a page's raw HTML or call an API, and you can parse the response. It cannot run JavaScript, click buttons or sign in through a browser, so JavaScript-rendered sites need a browser-based tool.

    Apps Script is a hosted scripting environment that runs inside Google's servers with built-in services for Sheets, Gmail and Drive. The Sheets API is a REST API you call from your own code, in any language, with per-minute request quotas and OAuth or service-account credentials.

    Related terms, automations and guides

    Where this concept shows up in practice.

    DefinitionGoogle Sheets APIThe Google Sheets API is Google's REST API for reading and writing Google Sheets from your own code. Version 4 exposes cell values, formatting, charts and sheet structure, and is limited by per-minute quotas of 300 requests per project and 60 per user, separately for reads and writes.DefinitionIMPORTXMLIMPORTXML is a Google Sheets function that fetches a URL from Google's servers and returns whatever an XPath query selects from the page, such as titles, prices or links. It reads only the raw HTML, so it cannot see content that JavaScript adds after the page loads.DefinitionIMPORTHTMLIMPORTHTML is a Google Sheets function that imports a whole HTML table or list from a web page into your spreadsheet, chosen by its position on the page. It is the quickest way to pull a static table into Sheets, and it shares IMPORTXML's limits: no JavaScript, no logins, hourly refresh.DefinitionCron JobA cron job is a command or script that runs automatically on a schedule written as a five-field cron expression (minute, hour, day of month, month, day of week), such as 0 9 * * 1-5 for 9:00 every weekday.DefinitionOAuth 2.0OAuth 2.0 is the IETF authorization standard (RFC 6749) that lets an app access your account in another service with a scoped token instead of your password. It powers 'Connect your Google account' buttons and nearly every app-to-app integration.DefinitionRate LimitingRate limiting is a technique that controls the number of requests a client can make to a server within a given time window, preventing abuse and ensuring fair resource distribution.DefinitionAPI IntegrationAPI integration is the process of connecting two or more applications through their APIs so they can exchange data and trigger actions automatically. It eliminates manual data entry by letting systems communicate directly with each other in real time.GuideIMPORTXML "Could Not Fetch URL" and "Imported Content Is Empty": Causes and FixesWhy Google Sheets' IMPORTXML and IMPORTHTML return "Could not fetch url", "Imported content is empty" or endless Loading, how to tell which cause you have in a minute, and what to use when the page is JavaScript-rendered, blocked or behind a login.

    Stop reading about automation.

    Start automating.

    Describe what you need in plain English. Autonoly's AI agent builds and runs the automation for you — no code required.

    See Features