---
title: Chat Google
description: Connect a Google Gemini chat model to AI nodes.
---

Give an AI node access to Google's Gemini models, through Google AI Studio or Vertex AI.

Pick a saved connection in the **Authentication** field, or create one from there.

## What it does

Chat Google is a model you plug into the **Model** slot of an AI node, such as the [Tools Agent](/nodes/builtin/ai/aiagents/toolsagentnode/) or [Basic LLM Chain](/nodes/builtin/ai/aiagents/basicllmchainnode/). It does not run on its own and has no output. When the AI node runs, it sends its messages to Google with your key and gets the reply back.

* **Platform Type** picks the service: `gai` is Google AI Studio (the Gemini API), `gcp` is Vertex AI on Google Cloud. Empty means `gai`.
* **Temperature** is 0 when you leave it empty, so answers are focused and repeatable.
* Replies are capped at **Max Tokens** (4096 by default). A failed request is retried up to **Max Retries** times (2 by default).

## When to use it

* You want a Gemini model, for example for long documents.
* You have a free or paid Google AI Studio key and want to start quickly.
* Your company runs Gemini on Google Cloud: choose `gcp`.

## Inputs and settings

Type the **Model** id as Google names it in its model list (a `gemini-...` id). Leave **Platform Type** empty or on `gai` for an AI Studio key; choose `gcp` only for a Vertex AI key.

## Outputs

This node has no output port. It plugs into a slot on another node instead of passing items along.

* **Model** slot of [Tools Agent](/nodes/builtin/ai/aiagents/toolsagentnode/), [Q\&A Agent](/nodes/builtin/ai/aiagents/qanode/), [RAG Agent](/nodes/builtin/ai/aiagents/ragnode/), [Basic LLM Chain](/nodes/builtin/ai/aiagents/basicllmchainnode/), [Indexer](/nodes/builtin/ai/aiagents/indexernode/), [Text Classifier](/nodes/builtin/ai/aiagents/textclassifiernode/), [Sentiment Analysis](/nodes/builtin/ai/aiagents/sentimentanalysisnode/), [Summarization](/nodes/builtin/ai/aiagents/summarizationchainnode/), [Information Extractor](/nodes/builtin/ai/aiagents/informationextractornode/), [Guardrails](/nodes/builtin/ai/aiagents/guardrails/), [Auto-fixing Output Parser](/nodes/builtin/ai/aidependencies/outputparser/autofixingoutputparser/)

The AI node you connect it to produces the output. Chat Google only decides which model answers.

## Dependencies and credentials

* **Authentication** (connection): required. See [Connect Google](/app/connections/google/).

In **Authentication**, save your Google API key (a Bearer Token or JWT Token credential both work; put only the key in it). See [Create a credential](/app/connections/create/).

* For **Google AI Studio** (`gai`), create the key at [aistudio.google.com/app/apikey](https://aistudio.google.com/app/apikey).
* For **Vertex AI** (`gcp`), create it in the Google Cloud Console, at [console.cloud.google.com/vertex-ai/studio/api-key](https://console.cloud.google.com/vertex-ai/studio/api-key/).

## Example workflow

1. A [Context Menu](/nodes/builtin/trigger/contextmenu/) trigger on the page.
2. [Get All Text](/nodes/extension/getalltext/) with **Output field name** `pageText`.
3. [Basic LLM Chain](/nodes/builtin/ai/aiagents/basicllmchainnode/) with **Prompt** `List the 5 key points of this article: {{ $input.pageText }}`.
4. Chat Google in its **Model** slot, with a Gemini model id and **Platform Type** `gai`.

## Common issues

* **"Model parameter is required and cannot be empty".** Fill in **Model**.
* **An "API key not valid" or permission error.** The key does not match **Platform Type**: an AI Studio key needs `gai`, a Vertex AI key needs `gcp`. Or the key was deleted; create a new one.
* **A "model not found" error.** The model id is misspelled or not available on that platform. Copy it from Google's model list.
* **The answer stops mid-sentence.** It hit **Max Tokens**. Raise it under **Options**.

## Related nodes

* [Google Embeddings](/nodes/builtin/ai/aidependencies/embeddings/google/): Gemini vectors for a knowledge base.
* [Chrome AI](/nodes/builtin/ai/aidependencies/llm/chrome-ai/): Gemini Nano, built into Chrome, no key.
* [Basic LLM Chain](/nodes/builtin/ai/aiagents/basicllmchainnode/): send one prompt and get a reply.
* [Tools Agent](/nodes/builtin/ai/aiagents/toolsagentnode/): an agent that can use tools and memory.