> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ctrlnode.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Gemini CLI provider

> Bridge provider gemini — Google Gemini CLI via ACP

Provider id: **`gemini`** · CtrlNode agent type: **`Gemini`**

Runs the [`@google/gemini-cli`](https://google-gemini.github.io/gemini-cli/) through **ACP** on stdio.

## When to use it

* You want Google Gemini models for coding tasks from CtrlNode
* You use `gemini` locally or on a VPS with API access

## Prerequisites

* **Node.js 20+**
* Gemini CLI:

```bash theme={null}
npm install -g @google/gemini-cli
gemini --version
```

## Authentication

**Option A — API key**

```env theme={null}
GEMINI_API_KEY=AIza...
```

**Option B — Google login**

```bash theme={null}
gemini auth login
```

## Environment variables

| Variable                 | Default | Description                |
| ------------------------ | ------- | -------------------------- |
| `GEMINI_API_KEY`         | —       | Google AI / Gemini API key |
| `GEMINI_TIMEOUT_MINUTES` | `10`    | Task timeout               |
| `BASE_PATH`              | Home    | Workspace root             |

## Example `.env`

```env theme={null}
PAIRING_TOKEN=...
PROVIDERS=gemini
GEMINI_API_KEY=AIza...
```

## CtrlNode setup

1. Project agent type **Gemini**
2. Register agents in **Team**
3. Pick model in the agent editor when the Bridge reports available models

## Troubleshooting

| Issue            | Fix                                                    |
| ---------------- | ------------------------------------------------------ |
| CLI not found    | Install globally; add `~/.local/bin` to PATH on Linux  |
| Auth errors      | `gemini auth login` or valid `GEMINI_API_KEY`          |
| Empty model list | API key optional for dispatch; key helps model listing |

[← All providers](/bridge/providers)
