Gemini DEPRECATED MODERATE 67 days left

gemini-embedding-001 — Deprecated

Deprecated
Shutdown
2026-07-14
Status
deprecated
Replacement

Quick fix — copy & paste

Choose your language. The "before" block matches the deprecated call; the "after" block is the drop-in replacement.

Breaks on 2026-07-14
# Gemini: gemini-embedding-001 (deprecated)
model = "gemini-embedding-001"
Use this instead
# No direct replacement — see Gemini docs.
# Pick a current model from the provider's available list.

This migration was generated automatically from the model rename. If your code does more than swap a model id, double-check request/response shapes against the official Gemini migration guide.

Error messages

Seeing one of these? You're in the right place.

  • model_not_found: gemini-embedding-001
  • The model `gemini-embedding-001` has been deprecated
  • The model `gemini-embedding-001` does not exist or you do not have access to it

Other Gemini deprecations

What this means for your code

gemini-embedding-001 is an embedding model that converts text into a vector for similarity search and RAG. Embeddings from different models are not interchangeable — you cannot mix vectors from the old model with vectors from the new model in the same index. Migration requires re-embedding your entire corpus.

Gemini has scheduled gemini-embedding-001 for shutdown on 2026-07-14. That gives you 67 days to migrate. Until then the model still works, but every API call after that date will return a model_not_found error.

Find every call in your codebase

Before you change anything, locate every place the deprecated model id is referenced. Search source files, environment files, feature flags, and config repos. Use these commands from your project root:

Python projects

grep -rn '"gemini-embedding-001"' --include="*.py" .

JavaScript / TypeScript projects

grep -rn '"gemini-embedding-001"' --include="*.{js,ts,tsx,jsx}" .

Anywhere (configs, scripts, infra)

grep -rn "gemini-embedding-001" .

Migration checklist

Steps in order. Skip any that don't apply, but read the whole list — for embedding models, the non-obvious steps are usually the ones that break in production.

  1. 1. Update the model id used in embedding generation
  2. 2. Re-embed your entire corpus with the new model — this is non-optional
  3. 3. Verify the new vector dimension matches your vector store's index configuration
  4. 4. Update similarity thresholds — different models have different distance distributions
  5. 5. Plan a cutover window where both old and new indices coexist before switching reads

Will this migration cost more?

Switching from gemini-embedding-001 to an alternative model could change your costs significantly. Calculate the exact difference for your prompts.

Open the cost calculator →