Skip to content
Google Apps Script · error message

Apps Script: Service invoked too many times for one day

RetryableDaily and rate quotas

Last verified

The exact message
Exception: Service invoked too many times for one day: urlfetch.

What it means

Google's quotas page says this exception indicates that the script called the given service too many times in one day. The service name at the end tells you which daily quota ran out: urlfetch for UrlFetchApp, email for sent mail, and so on.

Quotas are per user, not per script. Every script, add-on and custom function running as your account shares the same pool. For URL Fetch, Google lists 20,000 calls per day for consumer accounts and 100,000 for Google Workspace accounts; for email recipients it lists 100 per day on consumer accounts and 1,500 on Workspace.

Google states that quotas reset 24 hours after the first request, so the error clears on its own. It is not a problem with your code's logic, but it usually points to code that makes far more calls than needed, such as a custom function that fetches once per cell and recalculates often.

What it looks like

Exception: Service invoked too many times for one day: urlfetch.
    at fetchPrice(Code:12:30)

Why it happens

  • A custom function that calls UrlFetchApp in hundreds of cells, each recalculation consuming quota.
  • A time-driven trigger running every minute and fetching every time.
  • Several scripts or add-ons running under the same account, all drawing on the same daily pool.
  • A retry loop that keeps calling a failing endpoint.
  • Sending mail to more recipients in a day than the account allows.

How to fix it

  1. Read the service name in the message to identify which quota ran out.
  2. Check Executions and your triggers list to find what is calling the service most often.
  3. Cache responses with CacheService or store results in the sheet, and fetch only when data is stale.
  4. Combine requests: one API call for many items instead of one call per row.
  5. Lower trigger frequency to what the data actually needs.
  6. Wait for the quota to reset, then re-run; if the workload is legitimately large, run it under a Workspace account with the higher documented quota.

How to stop it recurring

Treat daily quotas as a budget. Cache, batch and schedule fetches rather than calling them from formulas that recalculate unpredictably. Log a counter of calls per run so you can see consumption trending toward the limit before it hits, and keep retries bounded.

Official documentation: developers.google.com/apps-script/guides/services/quotas. See all Apps Script error messages or the Apps Script limits and quotas.

Related errors

Definitions

Quick answers

What does "Service invoked too many times for one day" mean in Apps Script?

Google's quotas page says this exception indicates that the script called the given service too many times in one day. The service name at the end tells you which daily quota ran out: urlfetch for UrlFetchApp , email for sent mail, and so on. Quotas are per user, not per script. Every script, add-on and custom function running as your account shares the same pool.

How do I fix "Service invoked too many times for one day"?

1. Read the service name in the message to identify which quota ran out. 2. Check Executions and your triggers list to find what is calling the service most often. 3. Cache responses with CacheService or store results in the sheet, and fetch only when data is stale. 4. Combine requests: one API call for many items instead of one call per row. 5. Lower trigger frequency to what the data actually needs. 6. Wait for the quota to reset, then re-run; if the workload is legitimately large, run it under a Workspace account with the higher documented quota.

Run the job somewhere with its own limits

If a script keeps hitting its host's quotas, an Autonoly workflow can run the same steps on a schedule in an isolated cloud container, and the AI agent has a terminal with Python for steps that need code. Autonoly has limits of its own, priced in credits.

Also see Agent terminal & SSH.