# Avoid GPT formula timeouts in Sheets

## What is a timeout?

A timeout occurs when the [AI provider](https://autosheet.com/docs/resources/guides/concepts#ai-provider) takes more than 30 seconds to respond to a GPT formula request, or if the AI provider never responds (which is more rare). In such cases, the formula stops executing and returns a timeout error.

## What happens when a timeout occurs?

When a GPT formula times out:

- If caching is enabled (which is the default setting), most of the time the AI provider will have responded and the response is saved encrypted in the backend cache. Simply delete the formula from the cell and undo the deletion (press `Ctrl+Z`, or `Cmd+Z` on Mac) to retrieve its result **at no extra cost**. We recommend you [keep caching enabled](https://autosheet.com/docs/gpt-for-sheets/gpt-functions/manage-gpt-formulas/manage-cache).
- If caching is disabled, the result cannot be retrieved from the cache, and retrying the formula sends a new request to the AI provider.

## How to avoid timeouts

To reduce GPT formula timeouts in GPT for Sheets – Autosheet, set the [cut-off limit](https://autosheet.com/docs/gpt-for-sheets/gpt-functions/configure-behavior#set-the-cut-off-limit) to a lower value to reduce processing time.

To completely avoid timeouts:

- Use [Autosheet bulk tools](https://autosheet.com/docs/gpt-for-sheets/bulk-tools) whenever possible.
- Use [GPT for Excel – Autosheet](https://autosheet.com/docs/gpt-for-excel) if you need to use GPT functions in a spreadsheet.

> **Info**
>
> If you get 10 timeout errors within a minute using the same model, [GPT for Sheets – Autosheet cancels pending executions](https://autosheet.com/docs/gpt-for-sheets/troubleshooting/gpt-function-issues#slow). This prevents excessive billing when you drag a GPT formula across many cells and the model you are using is slow.
