Skip to content

Google Gemini

The Gemini functions call Google’s Generative Language API. Once licensed you need a Gemini API key from Google AI Studio, added via Set API Keys → Insert Gemini API Key.

Functions

FunctionModelGood for
=GEMINI(prompt, [system_prompt], [model_name], [ignore_cache])gemini-3.8-flash by default, or any model you namegeneral use, custom model choice
=Gemini4(prompt, [system_prompt], [ignore_cache])gemini-4-argonthe flagship reasoning model
=Gemini31Pro(prompt, [system_prompt], [ignore_cache])gemini-3.1-pro-previewcomplex writing and analysis
=Gemini38Flash(prompt, [system_prompt], [ignore_cache])gemini-3.8-flashfast everyday tasks
=Gemini35FlashLite(prompt, [system_prompt], [ignore_cache])gemini-3.5-flash-litethe fastest and cheapest option

Parameters

  • prompt (required): the user message.
  • system_prompt (optional): sent as the model’s system instruction. Pass "" to skip it when you need a later argument.
  • model_name (=GEMINI() only, optional): any Gemini model ID, with or without the models/ prefix. Retired IDs are mapped automatically.
  • ignore_cache (optional): TRUE forces a fresh API call. See Caching.

Examples

=GEMINI("Translate to French: " & A2)
=Gemini4("Which of these two pitches is more convincing and why? " & B2 & " | " & C2)
=Gemini35FlashLite(A2, "Classify as positive, neutral or negative. One word.")
=GEMINI("Summarize: " & D2, "Use at most 30 words", "gemini-3.1-pro-preview")
=GEMINI("Latest headline about " & A2, "", "gemini-3.8-flash", TRUE)

Legacy function names

Legacy functionNow runs on
=Gemini25Pro(), =Gemini15Pro()gemini-3.1-pro-preview
=Gemini25Flash(), =Gemini20Flash()gemini-3.8-flash
=Gemini15Flash()gemini-3.5-flash-lite

Legacy model names in =GEMINI()

You passRuns on
gemini-1.0-pro, gemini-1.5-pro, gemini-2.0-pro-exp, gemini-2.5-pro-preview-*, gemini-2.5-pro-exp-03-25, gemini-3-pro-previewgemini-3.1-pro-preview
gemini-2.0-flash, gemini-2.0-flash-001, gemini-2.0-flash-exp, gemini-2.5-flash-preview-*gemini-3.6-flash
gemini-1.5-flash, gemini-1.5-flash-8bgemini-3.5-flash-lite
gemini-2.0-flash-lite, gemini-2.0-flash-lite-001, gemini-2.5-flash-lite-preview-*, gemini-3.1-flash-lite-previewgemini-3.1-flash-lite

Errors

Cell showsMeaning
Error: Free trial for Gemini used up (10/10) ...Activate your license and add your own key.
Error: Gemini API key not set ...Add your key via Set API Keys → Insert Gemini API Key.
Error: API Error 400/403 ...The key was rejected or the model is not available to your key.
Error: Prompt blocked by API due to safety settingsGemini refused the prompt. Rephrase it.
Error: No prompt providedThe prompt cell is empty.