# @ai-sdk/google

Latest version **4.0.78** (published 2026-09-23) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install @ai-sdk/google
pnpm add @ai-sdk/google
yarn add @ai-sdk/google
bun add @ai-sdk/google
```

## Health

**Score 60/100 (C)** — status: active.

Positive: no vulnerabilities; recently updated; high maintenance score; popular repo.

Warnings: low downloads; no types; no esm support.

## Facts

| | |
|---|---|
| Version | 4.0.78 |
| Published | 2026-09-23 |
| First published | 2024-04-12 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 26864 |
| Maintainers | vercel-release-bot, matheuss, matt.straka |
| Keywords | ai |

## Links

- npm: https://www.npmjs.com/package/@ai-sdk/google
- Repository: https://github.com/vercel/ai
- Homepage: https://ai-sdk.dev/docs
- Issues: https://github.com/vercel/ai/issues
- npm.io page: https://npm.io/package/@ai-sdk/google

## Alternatives

- [@expo/fingerprint](https://npm.io/package/@expo/fingerprint.md) — 6.2M weekly downloads
- [@azure/monitor-opentelemetry-exporter](https://npm.io/package/@azure/monitor-opentelemetry-exporter.md) — 850.0K weekly downloads
- [@azure/monitor-opentelemetry](https://npm.io/package/@azure/monitor-opentelemetry.md) — 624.0K weekly downloads
- [@posthog/ai](https://npm.io/package/@posthog/ai.md) — 423.3K weekly downloads
- [fakefilter](https://npm.io/package/fakefilter.md) — 63.9K weekly downloads

## Recent versions

- 4.0.78 (latest) — 2026-09-23
- 3.0.126 (ai-v6) — 2026-09-23
- 2.0.98 (ai-v5) — 2026-09-23
- 0.0.0-f1630544-20260811180950 (snapshot) — 2026-08-11
- 4.0.0-beta.85 (beta) — 2026-06-23
- 4.0.0-canary.81 (canary) — 2026-06-12
- 2.0.0-alpha.15 (alpha) — 2025-06-18
- 4.0.77 — 2026-09-22
- 3.0.125 — 2026-09-21
- 4.0.76 — 2026-09-18
- 3.0.124 — 2026-09-18
- 4.0.75 — 2026-09-18
- 4.0.74 — 2026-09-16
- 3.0.123 — 2026-09-16
- 4.0.73 — 2026-09-16
- … 659 more at https://npm.io/package/@ai-sdk/google/versions

## README

# AI SDK - Google Provider

The **[Google provider](https://ai-sdk.dev/providers/ai-sdk-providers/google)** for the [AI SDK](https://ai-sdk.dev/docs) contains language model support for the [Google Generative AI](https://ai.google/discover/generativeai/) APIs.

> **Deploying to Vercel?** With Vercel's AI Gateway you can access Google (and hundreds of models from other providers) — no additional packages, API keys, or extra cost. [Get started with AI Gateway](https://vercel.com/ai-gateway).

## Setup

The Google provider is available in the `@ai-sdk/google` module. You can install it with

```bash
npm i @ai-sdk/google
```

## Skill for Coding Agents

If you use coding agents such as Claude Code or Cursor, we highly recommend adding the AI SDK skill to your repository:

```shell
npx skills add vercel/ai
```

## Provider Instance

You can import the default provider instance `google` from `@ai-sdk/google`:

```ts
import { google } from '@ai-sdk/google';
```

## Example

```ts
import { google } from '@ai-sdk/google';
import { generateText } from 'ai';

const { text } = await generateText({
  model: google('gemini-2.5-pro'),
  prompt: 'Write a vegetarian lasagna recipe for 4 people.',
});
```

## Documentation

Please check out the **[Google provider documentation](https://ai-sdk.dev/providers/ai-sdk-providers/google)** for more information.

---
_Source: https://npm.io/package/@ai-sdk/google · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
