Skip to main content
This page covers all LangChain integrations with Google Gemini, Google Cloud, and other Google products (such as Google Maps, YouTube, and more).
Unified SDK & package consolidationAs of langchain-google-genai 4.0.0, this package uses the consolidated google-genai SDK and now supports both the Gemini Developer API and Vertex AI backends.The langchain-google-vertexai package remains supported for Vertex AI platform-specific features (Model Garden, Vector Search, evaluation services, etc.).Read the full announcement and migration guide.
Not sure which package to use?
Access Google Gemini models via the Gemini Developer API or Vertex AI. The backend is selected automatically based on your configuration.
  • Gemini Developer API: Quick setup with API key, ideal for individual developers and rapid prototyping
  • Vertex AI: Enterprise features with Google Cloud integration (requires GCP project)
Use the langchain-google-genai package for chat models, LLMs, and embeddings.See integrations.
Access Vertex AI platform-specific services beyond Gemini models: Model Garden (Llama, Mistral, Anthropic), evaluation services, and specialized vision models.Use the langchain-google-vertexai package for platform services and specific packages (e.g., langchain-google-community, langchain-google-cloud-sql-pg) for other cloud services like databases and storage.See integrations.
See Google’s guide on migrating from the Gemini API to Vertex AI for more details on the differences.

Google Generative AI

Access Google Gemini models via the Gemini Developer API or Vertex AI using the unified langchain-google-genai package.

Chat models

LLMs

Embedding models


Google Cloud

Access Vertex AI platform-specific services including Model Garden (Llama, Mistral, Anthropic), Vector Search, evaluation services, and specialized vision models.
For Gemini models, use ChatGoogleGenerativeAI from langchain-google-genai. The classes below focus on Vertex AI platform services not available in the consolidated SDK.

Chat models

Deprecated — Use ChatGoogleGenerativeAI for Gemini models instead.
from langchain_google_vertexai import ChatVertexAI
Llama on Vertex AI Model Garden
from langchain_google_vertexai.model_garden_maas.llama import VertexModelGardenLlama
Mistral on Vertex AI Model Garden
from langchain_google_vertexai.model_garden_maas.mistral import VertexModelGardenMistral
Local Gemma model loaded from HuggingFace.
from langchain_google_vertexai.gemma import GemmaChatLocalHF
Local Gemma model loaded from Kaggle.
from langchain_google_vertexai.gemma import GemmaChatLocalKaggle
Gemma on Vertex AI Model Garden
from langchain_google_vertexai.gemma import GemmaChatVertexAIModelGarden
Image captioning model as a chat interface.
from langchain_google_vertexai.vision_models import VertexAIImageCaptioningChat
Edit images given a prompt. Currently supports mask-free editing only.
from langchain_google_vertexai.vision_models import VertexAIImageEditorChat
Generate images from a prompt.
from langchain_google_vertexai.vision_models import VertexAIImageGeneratorChat
Visual question answering model as a chat interface.
from langchain_google_vertexai.vision_models import VertexAIVisualQnAChat

LLMs

(Legacy) string-in, string-out LLM interface.
Deprecated — Use GoogleGenerativeAI for Gemini models instead.
from langchain_google_vertexai import VertexAI
Local Gemma model loaded from HuggingFace.
from langchain_google_vertexai.gemma import GemmaLocalHF
Local Gemma model loaded from Kaggle.
from langchain_google_vertexai.gemma import GemmaLocalKaggle
from langchain_google_vertexai.gemma import GemmaVertexAIModelGarden
Image captioning model as an LLM interface.
from langchain_google_vertexai.vision_models import VertexAIImageCaptioning

Embedding models

Deprecated — Use GoogleGenerativeAIEmbeddings instead.
from langchain_google_vertexai import VertexAIEmbeddings

Document loaders

Load data using Google Cloud Vision API.
from langchain_google_community.vision import CloudVisionLoader

Document transformers

Vector stores

Store and search vectors using Google Cloud databases and Vertex AI Vector Search.

Retrievers

Other retrievers
from langchain_google_community import VertexAIMultiTurnSearchRetriever
from langchain_google_community import VertexAISearchRetriever
from langchain_google_community import VertexAISearchSummaryTool

Tools

Integrate agents with various Google Cloud services.

Callbacks

Track LLM/Chat model usage.
Track VertexAI usage info.
from langchain_google_vertexai.callbacks import VertexAICallbackHandler
See the documentation for more details.
from langchain_google_community.callbacks.bigquery_callback import BigQueryCallbackHandler

Evaluators

Evaluate model outputs using Vertex AI.
Pair-wise evaluation using Vertex AI models.
from langchain_google_vertexai.evaluators.evaluation import VertexPairWiseStringEvaluator
Single prediction evaluation using Vertex AI models.
from langchain_google_vertexai.evaluators.evaluation import VertexStringEvaluator

Other Google products

Integrations with various Google services beyond the core Cloud Platform.

Document loaders

Vector stores

Retrievers

Tools

MCP

Toolkits

Chat loaders


3rd party integrations

Access Google services via unofficial third-party APIs.

YouTube


Connect these docs to Claude, VSCode, and more via MCP for real-time answers.