Clarification on Google Workspace and Apps Script Quotas and Limits

506 views
Skip to first unread message

Saikumar Pole

unread,
Sep 18, 2023, 9:35:34 AM9/18/23
to Google Apps Script Community

I have been working on a project where I use Google Workspace and Google Apps Script to edit spreadsheets. While I have gone through the official documentation here, I still have some questions regarding the quotas and limits associated with these services. I hope someone with experience in this area can provide some clarification:

  1. Maximum Number of API Calls (POST) per day:

I am trying to understand the daily limit on the number of API calls (specifically POST requests) that I can make when using Google Apps Script to edit Google Sheets. Having this information is crucial for effective script management.

  1. Maximum Allowed Execution Time for the Script:

Could someone please provide clarity on the maximum duration for which an Apps Script can run? Knowing this limit is essential for planning and optimizing the execution of my scripts.

  1. Reset Timing for Execution Time Limit:

I would like to know when the execution time limit resets. Does it start at a specific time, such as 12:01 AM, or does it reset upon the first API (POST) call made after reaching the limit? Understanding the timing of the reset is crucial for scheduling and managing my scripts effectively.

I would greatly appreciate any insights or experiences you can share regarding these quotas and limits. Clearing up these uncertainties will help me ensure the smooth operation of my Apps Script within the established guidelines.

Thank you in advance for your assistance!

I read the documentation and different pages but no help

DimuDesigns

unread,
Sep 18, 2023, 10:58:00 AM9/18/23
to Google Apps Script Community
I'm just regurgitating what's already stated on the quotas page but I'll try to clarify.

Apps Script can only make HTTP Requests from its URLFetchApp service. So that means if you're using a consumer grade account (one whose email address ends in gmail.com) the max number of requests you can make per day is 20,000 across all HTTP methods (GET, POST, PUT, PATCH, DELETE, etc.). If you have a business-grade Google Workspace account you can make up to 100,000 requests per day. Now that's just an upper-bound, Google might choose to throttle requests based on workload so its not a guarantee.

The max execution time for a script (per invocation) is 6 minutes. There have been exceptions to that rule in the past (business-grade accounts had up to 30-minute execution times at one point) but those days seem to be behind us. Its 6-minutes across the board - take that as the rule.

I assume that by 'Reset Timing' you are referring to time-based triggers. If I recall correctly, you get 90-minutes total trigger execution per day (cumulative sum of executions times per invocation in one day, where each individual execution cannot exceed 6 minutes) . If you exhaust that quota your trigger returns an error. Google's policy around triggers are somewhat strict so if you try to abuse them Google has no qualms deleting your trigger,
Reply all
Reply to author
Forward
0 new messages