GPT functions for Google Sheets
Compare Starter, Pro, Business and Lifetime plans for AI formulas, Claude/Gemini/OpenRouter, bulk SEO workflows and lead enrichment.
See GPT for Sheets pricing →
Links:
- Install the GPT for Sheets, Docs, Slides, Forms add-on
- Upgrade to Premium
- Optional -> RECOMMENDATION: The best way to ensure optimal performance with Google Add-Ons is by using the Google Chrome browser. This helps bypass any potential issues that may arise from compatibility with other browsers.
All functions — full reference
Every function has its own reference page with syntax, parameters and copy-paste examples:
| Function | What it does | Reference |
|---|---|---|
=GPT() |
Generate text from a prompt in one cell | =GPT() reference |
=GPT_TABLE() |
Generate a whole table that spills into rows and columns | =GPT_TABLE() reference |
=GPT_LIST() |
Generate a vertical list, one item per cell | =GPT_LIST() reference |
=GPT_FILL() |
Autofill a range by learning from example rows | =GPT_FILL() reference |
=GPT_EXTRACT() |
Pull emails, names, prices out of messy text | =GPT_EXTRACT() reference |
=GPT_CLASSIFY() |
Put each row into one of your categories | =GPT_CLASSIFY() reference |
=GPT_TAG() |
Apply all relevant labels to a text | =GPT_TAG() reference |
=GPT_SUMMARIZE() |
Condense long text into a summary of any length | =GPT_SUMMARIZE() reference |
=GPT_FORMAT() |
Convert between formats: HTML, JSON, Markdown, table… | =GPT_FORMAT() reference |
=GPT_APPLY() |
Apply an instruction to text (default: fix grammar) | =GPT_APPLY() reference |
=GPT_TRANSLATE() |
Translate cells between languages | =GPT_TRANSLATE() reference |
=GPT_VISION() |
Ask questions about an image by URL | =GPT_VISION() reference |
=GPT_WEB_SEARCH() |
Answers grounded in a live web search | =GPT_WEB_SEARCH() reference |
=GPT_CREATE_IMAGE() |
Generate images with DALL·E / GPT image models | =GPT_CREATE_IMAGE() reference |
=CLAUDE() |
Use Anthropic Claude with the same arguments as GPT | =CLAUDE() reference |
=GEMINI() |
Use Google Gemini for fast, high-volume tasks | =GEMINI() reference |
=MISTRAL() |
Use Mistral for fast, low-cost bulk processing | =MISTRAL() reference |
=PERPLEXITY() |
Web-aware answers for research and enrichment | =PERPLEXITY() reference |
=SERP() |
Fetch live search results into your sheet | =SERP() reference |
=GROK() |
Use xAI Grok on your own API key (Pro/Business plans) | =GROK() reference |
=DEEPSEEK() |
Use DeepSeek on your own API key for low-cost bulk runs | =DEEPSEEK() reference |
Example of use
-
Here you can find a Google Sheet Template with examples Google Sheet Template. The file is accessible in read-only mode. To make modifications, please create a copy using File > Make a copy, or you can simply copy functions/examples into your own sheet.
Important!

After getting a final result, please click on ‘Replace All GPTs’ or ‘Replace Selected’ button to replace the formula with the result. If to don’t do this - Google Sheets re-execution all formulas on refreshing page and every 1–2 minutes. (could affect your credits on Open AI or Internal credits, depends on plan)
GPT
The most straightforward function to initiate GPT in Google Sheets. Generates the outcome within a single cell.
| Function | =GPT(prompt, [value]) |
|---|---|
| Description | Tell the AI what to generate in one cell. |
| Localization | In some locales, use “;” to separate parameters instead of “,” |
| Example | =GPT("Write a tagline for a car") |
| Example 2 | =GPT(A1, "my site") |
| Example 3 | =GPT(A1, B1) |
| Output (one cell) | Unleash the power of motion |
Parameters
| Parameter | Definition |
|---|---|
prompt (required) |
Instruction given to the AI to generate a result. - It can be a string - a cell reference (e.g., B1), - range of cells (e.g., B1:E4). |
(optional) value |
Additional input or context to influence the output. It can be text, a cell, or a range. |
GPT_TRANSLATE
| Function | =GPT_TRANSLATE(text, target, [source]) |
|---|---|
| Description | Translates input text into another language using GPT. |
| Localization | In some locales, use “;” to separate parameters instead of “,” |
| Example | =GPT_TRANSLATE("I love ice cream", "spanish", "english") |
Parameters
| Parameter | Definition |
|---|---|
text (required) |
Instruction given to the AI to generate a result. - It can be a string - a cell reference (e.g., B1), - range of cells (e.g., B1:E4). |
target (required) |
Specify the desired language |
source (optional) |
Specify the source language |
GPT_FORMAT
| Function | =GPT_FORMAT(text, target_format) |
|---|---|
| Description | Converts between formats. |
| Localization | In some locales, use “;” to separate parameters instead of “,” |
| Example | =GPT_FORMAT("<ul><li><p>Name: Joe</p><p>Age: 27</p></li><li><p>Name: Jane</p><p>Age: 28</p></li></ul>", "json") |
Parameters
| Parameter | Definition |
|---|---|
prompt (required) |
Instruction given to the AI to generate a result. - It can be a string - a cell reference (e.g., B1), - range of cells (e.g., B1:E4). |
target_format (required) |
Specify the desired conversion format: JSON, HTML, YAML, Markdown, programming languages, etc. |
GPT_TAG
| Function | =GPT_TAG(text, [tags]) |
|---|---|
| Description | Applies user-defined tags to a given text |
| Localization | In some locales, use “;” to separate parameters instead of “,” |
| Example | =GPT_TAG("I love chocolate", "food, positive, negative") |
Parameters
| Parameter | Definition |
|---|---|
text (required) |
Instruction given to the AI to generate a result. - It can be a string - a cell reference (e.g., B1), - range of cells (e.g., B1:E4). |
tags (optional) |
Specify the desired tags |
GPT_CLASSIFY
| Function | =GPT_CLASSIFY(text, categories) |
|---|---|
| Description | Classifies the input into one of the given categories. Make sentiment analysis for comments, feedbacks, text |
| Localization | In some locales, use “;” to separate parameters instead of “,” |
| Example | =GPT_CLASSIFY("banana", "fruit, vegetable") |
Parameters
| Parameter | Definition |
|---|---|
text (required) |
Instruction given to the AI to generate a result. - It can be a string - a cell reference (e.g., B1), - range of cells (e.g., B1:E4). |
categories (optional) |
Specify the desired categories |
GPT_EXTRACT
| Function | =GPT_EXTRACT(text, to_extract) |
|---|---|
| Description | Extracts data (like email addresses or company names) from a text. Outputs as comma-separated values. |
| Localization | In some locales, use “;” to separate parameters instead of “,” |
| Example | =GPT_EXTRACT("I worked 12 years at Amazon.com at Apple", "companies") |
Parameters
| Parameter | Definition |
|---|---|
text (required) |
Instruction given to the AI to generate a result. - It can be a string - a cell reference (e.g., B1), - range of cells (e.g., B1:E4). |
to_extract (optional) |
Specify the desired extraction: emails, first name, last name, countries… |
GPT_SUMMARIZE
| Function | =GPT_SUMMARIZE(text, [format]) |
|---|---|
| Description | Summarizes the input text using GPT and returns the summary. |
| Localization | In some locales, use “;” to separate parameters instead of “,” |
| Example | =GPT_SUMMARIZE("This is a long text. It contains a lot of information. We need to summarize it.") |
| Example 2 | =GPT_SUMMARIZE("This is a long text. It contains a lot of information. We need to summarize it.", "two sentences") |
Parameters
| Parameter | Definition |
|---|---|
text (required) |
Instruction given to the AI to generate a result. - It can be a string - a cell reference (e.g., B1), - range of cells (e.g., B1:E4). |
format (optional) |
Specify the summarization format like: two sentences, up to 100 words, etc |
GPT_TABLE
| Function | =GPT_TABLE(prompt, headers) |
|---|---|
| Description | Generates a table from a prompt. |
| Localization | In some locales, use “;” to separate parameters instead of “,” |
| Example | =GPT_TABLE("top 10 most eaten fruits and their nutrition data", "name, calories") |
Parameters
| Parameter | Definition |
|---|---|
prompt (required) |
Instruction given to the AI to generate a result. - It can be a string - a cell reference (e.g., B1), - range of cells (e.g., B1:E4). |
headers (required) |
Additional input or context to influence the output. It can be text, a cell, or a range. |