← all posts
migration·Lukas Babaliauskas·Oct 21, 2026·updated Nov 25, 2026·12 min read

Gemini model deprecation: dates, replacements and a migration checklist

Gemini 2.5 Pro and Flash are deprecated, and the Gemini API reroutes them on December 1, 2026. Dates, replacements and a six-step migration checklist.

Gemini 2.5 Pro, 2.5 Flash and 2.5 Flash-Lite are past their October 20, 2026 retirement date on Vertex AI, and on the Gemini API Google deprecated 2.5 Pro and 2.5 Flash on November 2, 2026. Move to gemini-3.8-flash, Google's listed replacement for almost every retired text model, or gemini-3.5-flash-lite where cost matters more than capability. Pin the new ID, and replay real traffic on the old and new model before you switch.

Vertex AI is now documented as Gemini Enterprise Agent Platform. On the Gemini Developer API, the one you reach with an AI Studio key, 2.5 Pro and 2.5 Flash are served only to projects that already used them, and from December 1, 2026 requests for 2.5 Pro go to gemini-3.8-flash and requests for 2.5 Flash to gemini-3.5-flash-lite, billed at the new model's rates. gemini-2.5-flash-lite has no shutdown date there. gemini-3.6-flash is past its November 19, 2026 retirement date on Vertex, so the next hard date is that December 1 reroute.

The migration checklist, short version:

  1. +Inventory every Gemini model ID your code, configs and eval harness call, and note which surface each call goes through: Vertex or the Gemini API.
  2. +Look up each date on that surface's page. The two surfaces publish different dates for the same model ID.
  3. +Pick a pinned replacement, not a -latest alias, and check that it is not itself on a short clock.
  4. +Update the request. thinking_budget becomes thinking_level, temperature is ignored, a few parameters now return errors, and function-calling history is stricter.
  5. +Replay real production traffic on the old and new model, and diff tool calls, JSON fields and refusals, not just whether the answers read well.
  6. +Cut over per route with a rollback path, and put the replacement's own retirement date on the calendar.

The rest of this post is the detail behind each step, with the dates as of November 25, 2026. They come from Google's Gemini API deprecations page ↗ and the Vertex model versions page ↗. Check both before you act on any row, because Google updates them often. For every current model ID with its context window and price, not only the retiring ones, see the Gemini models list. A disclosure: I build EvalShift, a tool for step 5, and it has a short section near the end. The rest works with any tool or none.

Which Gemini models are deprecated right now?

All three Gemini 2.5 text models are past their retirement date on Vertex, 2.5 Pro and 2.5 Flash are deprecated on the Gemini API, and the 2.0 models are shut down on both. gemini-3.6-flash is past its November 19, 2026 retirement date on Vertex, and the next Vertex text model to go is gemini-3.7-flash, on January 28, 2027:

Model IDGemini API (AI Studio key)Vertex AI / Agent PlatformListed replacement
gemini-2.5-proDeprecated November 2, 2026. Existing users only. Routed to gemini-3.8-flash from December 1, 2026Retirement date October 20, 2026 (passed)gemini-3.8-flash or gemini-3.5-flash
gemini-2.5-flashDeprecated November 2, 2026. Existing users only. Routed to gemini-3.5-flash-lite from December 1, 2026Retirement date October 20, 2026 (passed)gemini-3.8-flash or gemini-3.5-flash-lite
gemini-2.5-flash-liteNo shutdown date. Existing users onlyRetirement date October 20, 2026 (passed)gemini-3.8-flash, gemini-3.5-flash-lite or Gemma 4
gemini-2.0-flash, gemini-2.0-flash-liteShut down June 1, 2026Retired June 1, 2026Differs by surface, see below
gemini-3-pro-previewShut down March 9, 2026—gemini-3.1-pro-preview
gemini-3.5-flashNot shutting down. Requests are routed to gemini-3.6-flashAvailable until at least May 19, 2027—
gemini-3.6-flashNo shutdown date announcedRetirement date November 19, 2026 (passed)gemini-3.8-flash
gemini-3.7-flashNot shutting down. Requests are routed to gemini-3.8-flashRetires January 28, 2027gemini-3.8-flash
gemini-3.1-flash-liteEarliest shutdown May 7, 2027Available until at least May 7, 2027gemini-3.5-flash-lite
text-embedding-004Shut down January 14, 2026Retires April 1, 2027gemini-embedding-2 on the Gemini API; Vertex lists none
gemini-embedding-001Earliest shutdown May 14, 2028No sooner than May 20, 2028gemini-embedding-2

A dash means the page for that surface lists nothing. For the 2.0 models the two pages disagree: the Gemini API lists gemini-3.6-flash for gemini-2.0-flash and gemini-3.1-flash-lite for gemini-2.0-flash-lite, while Vertex lists gemini-3.5-flash-lite for both. Not all of 2.5 goes at once: both surfaces list March 15, 2027 for gemini-2.5-flash-image.

Voice and audio models have their own deadlines. On the Gemini API, gemini-2.5-flash-preview-tts, gemini-2.5-pro-preview-tts and gemini-3.1-flash-tts-preview shut down on December 18, 2026, in favor of the gemini-3.8-flash-tts models, and gemini-2.5-flash-native-audio-preview-12-2025 shuts down on March 31, 2027, with gemini-3.8-live as its replacement. On Vertex, gemini-live-2.5-flash-native-audio retires on December 13, 2026.

If you need a Pro-class model rather than a Flash one, note that Vertex lists only Flash models as the replacement for 2.5 Pro. The Pro-class options are gemini-3.1-pro-preview, which is still a preview, and the Gemini 4 models: gemini-4-argon, released October 13, 2026, gemini-4-carbon, released November 10, 2026, which Google now calls its strongest reasoning model, and gemini-4-hydrogen and gemini-4-neon, released November 12 and November 18. Argon comes with its own migration notes ↗: it does not support explicit caching, and Google asks for HTTP client timeouts of at least 15 minutes.

Why does the same Gemini model have two retirement dates?

The Gemini API and Vertex are separate products with separate lifecycle policies, and the October 20 retirement date only applies to Vertex. Which one your code hits depends on how the client is built, not on the model string. With the google-genai SDK, a client created with vertexai=True (or through the environment variables that select Vertex, such as GOOGLE_GENAI_USE_VERTEXAI, plus a project and location) runs on Vertex. A client created with an API key runs on the Gemini API.

The two policies also promise different things:

  • +Vertex splits models into two tables. Models in the first are available for at least 12 months after release. Models with a shorter availability period, like gemini-3.6-flash and gemini-3.7-flash, stay up until a replacement ships and Google posts a fixed retirement date at least 45 days out. Vertex dates can be extended but are never moved earlier.
  • +The Gemini API lists the earliest date a model might be shut down and promises to communicate the exact date in advance. Once a model is shut down, its endpoint is gone.

So the practical rule is that the date that applies to you is the one on the page for the surface your client talks to. Teams that run the API in development and Vertex in production can have one environment working and the other failing on the same model ID.

Which Gemini model changes don't fail a single request?

Auto-routing and -latest aliases. Both swap the model behind your calls on the Gemini API without an error, where a shutdown is loud: your calls fail and someone gets paged.

  • +Auto-routing. The Gemini API sends requests for gemini-3.5-flash to gemini-3.6-flash, and requests for gemini-3.7-flash to gemini-3.8-flash, both since October 8, 2026 per Google's changelog ↗. From December 1, 2026, it also sends gemini-2.5-pro to gemini-3.8-flash and gemini-2.5-flash to gemini-3.5-flash-lite, billed at the new model's rates. If you call any of these IDs, you have migrated, or will on December 1, without a test run and without a diff. The 2.5 reroutes are the risky ones: the targets are Gemini 3 models with the request changes in step 4, and Google deprecated temperature, top_p and top_k in July 2026, so a call that relied on temperature=0 for repeatable output can't count on it after December 1.
  • +-latest aliases. An ID like gemini-flash-latest is hot-swapped with every new release of that model. Google promises two weeks' email notice before the version behind the alias changes, and then the swap happens without any change on your side.

Both are the same failure in different clothes: the model behind your feature changed and the config file did not. You can at least see it happen, because every response says which model answered. Log it next to each call:

python
from google import genai

client = genai.Client()
resp = client.models.generate_content(model="gemini-3.7-flash", contents="ping")
print(resp.model_version)  # the model that actually served the request

An alert on a change in model_version per route catches a swap the day it happens, instead of when a downstream count drifts.

Step 1: inventory every Gemini model ID and the surface it runs on

Grep for every Gemini model ID and read each hit:

bash
grep -rhoE "(gemini|text-embedding)-[a-z0-9.-]*[0-9][a-z0-9.-]*|gemini-[a-z-]*latest" \
  --exclude-dir={node_modules,.git,.venv,dist} . | sort | uniq -c | sort -rn

Model strings hide in more places than the application code: environment files, Terraform, prompt registries, notebooks, batch jobs, and the eval harness itself, where judge and embedding models are easy to forget. For each ID, write down three things: the surface (Vertex or Gemini API), the route or feature that calls it, and what it does there: tool calling, JSON output, free text, embeddings or audio. That last column decides how much testing step 5 needs.

Two kinds of model need more than a string change. Embedding models are one: vectors from different embedding models are not comparable, so moving from gemini-embedding-001 to gemini-embedding-2 means re-embedding your whole index and re-checking retrieval quality, not just changing the query-side call. Tuned models are the other. If you fine-tuned a 2.5 model on Vertex, check what the replacement supports before you plan around it. A forum thread from August 2026 points out that Vertex documents batch inference as unsupported for tuned Gemini 3 and higher models.

Step 2: look up each date on the page for that surface

Put each ID from step 1 against the deprecations page for its surface: the Gemini API page ↗ for API keys, the Vertex page ↗ for Vertex clients. Sort by date. Anything already past its date is an outage or an unplanned migration you have already shipped. Anything inside 45 days is this sprint.

Step 3: choose a pinned replacement, not an alias

Use the replacement Google lists, as a pinned ID, and check its own row before you commit to it. The obvious trap right now: on the Gemini API, gemini-2.0-flash lists gemini-3.6-flash as its replacement, and on Vertex gemini-3.6-flash is already past its November 19, 2026 retirement date. Migrating onto a model with a short clock means doing this twice. gemini-3.8-flash is listed on Vertex as available until at least September 2, 2027, and it is the ID most of the table above points to.

A -latest alias looks like a way out of the deprecation treadmill. It is the opposite: it swaps the model under you with every release, and you lose the before-and-after comparison that makes a migration safe.

Step 4: update the request for Gemini 3.8 Flash

Remove the parameters 3.8 Flash rejects or ignores, map thinking_budget to thinking_level, and fix function-calling history. Google's developer guide to Gemini 3.8 Flash ↗ lists what changes in the request. Coming from 2.5, these are the lines that matter:

In your 2.5-era requestOn gemini-3.8-flashWhat to do
temperature, top_p, top_kIgnored by the backend. No errorRemove them, and stop relying on temperature=0 for repeatable output. See step 5
thinking_budget (an integer)Replaced by thinking_level: LOW, MEDIUM (the default) or HIGHMap each budget to a level. The lowest is LOW, so a 2.5 Flash call with thinking_budget=0 cannot keep thinking off
thinking_level: MINIMALAPI validation errorUse LOW
candidate_count, frequency_penalty, presence_penaltyAPI errorRemove them
A prefilled model turn, or history ending on a model turn400 INVALID_ARGUMENT: "Requests ending with a model turn are not supported."Remove it. Use structured output to force a format. Causes and fixes
A FunctionResponse that doesn't echo its callMust match the id, name and execution count of the preceding FunctionCallPass back the call's id and name on every response
Rebuilding chat history from stored textGemini 3 models expect thought signatures back in multi-turn and function-calling historySend history back as the API returned it, signatures included

The ignored temperature is the dangerous row, because nothing fails. Code that set temperature=0 to make a classifier repeatable keeps running on 3.8 Flash and is no longer repeatable. If you target a Gemini 3 Pro-class model instead, Google's advice runs the other way: keep temperature at its default of 1.0, because lower values can cause looping or degraded output. PDF and video inputs also change token counts under Gemini 3's media_resolution settings, so check the cost of any document-heavy route.

Step 5: replay production traffic on both models and diff the behavior

Run the same real production inputs through the old and new model, and diff what each one does, not how its answers read. Everything up to here makes the new model answer; this step finds out whether it still does the same job. A model swap is a behavior change, and the regressions that matter mostly read fine: a tool argument changes format, an enum field moves one notch, a request the old model refused turns into a tool call. Reading a few outputs in AI Studio will not show you any of that.

The method, in brief:

  • +Build the cases from production logs, not from prompts you make up: 100 to 300 real inputs, stratified by route, with what production actually did (tool calls, arguments, JSON fields) stored as the expectation.
  • +Assert deterministically first. Check the tools called, the argument formats, and field equality on every enum. Use an LLM judge only for free text, and treat its results as advisory.
  • +Take several samples per case on 3.8 Flash. With temperature ignored, one sample cannot tell a regression from sampling noise. Score the fraction of samples that pass.
  • +Compare per route, never one average. A 5% drop on one route disappears in the overall number.

There is one timing problem specific to this deprecation. If you are on Vertex, 2.5 is past its October 20 retirement date, so the only baseline you can count on is what you logged before then. If you are on the Gemini API and your project still has 2.5 access, record a baseline run before December 1, 2026, while the old model still answers. After that, gemini-2.5-pro and gemini-2.5-flash answer with a different model. gemini-3.6-flash is past its November 19 retirement date on Vertex, so there too the only baseline left is what you logged before then.

The full walkthrough of this step, with code and the six regressions it caught on a real model upgrade, is in How to catch LLM regressions before a model upgrade ships.

Step 6: cut over with a rollback path

Switch one route at a time, behind a flag, starting with the route the diff in step 5 cleared most clearly. Where the old model still answers (Gemini API projects with 2.5 access, until December 1 for Pro and Flash), keep it as the fallback until the new route has run for a week. Watch error rates, latency, cost and model_version per route. Then add the replacement's own retirement date to the team calendar, with a reminder 45 days ahead, because this checklist will run again.

Doing this with EvalShift

Disclosure: I'm the founder of EvalShift, and step 5 is the part it automates. The capture SDK wraps the google-genai client and records real runs, including tool calls and the generation config, and compare replays them against the candidate model:

python
from google import genai
from evalshift import capture
from evalshift.adapters.genai import wrap_genai

client = wrap_genai(genai.Client())  # records each call inside a capture session

TOOLS = [...]  # the function declarations the agent is offered, or [] for none

@capture.agent(suite="support", redact=True, tools=TOOLS)  # no-op unless EVALSHIFT_CAPTURE=1
def handle_ticket(message): ...
bash
pip install evalshift
EVALSHIFT_CAPTURE=1 python my_agent.py   # record production-shaped runs
evalshift capture sync                   # recorded runs -> golden suite
evalshift compare --suite-name support --to gemini-3.8-flash

Both arms are live calls, so run it while the old model still answers. When it no longer does, the tool evaluators can still score the candidate against the trace production recorded (against: expected). For the ignored temperature, set defaults.samples_per_example above 1 so each case is sampled several times. The verdict comes from a migration_policy written before the run, and the report shows the per-example diff. Docs: /docs/sdk-adapters, /docs/evaluators, /docs/migration-policy.

FAQ

Is Gemini 2.5 Flash deprecated? Yes. Vertex AI lists October 20, 2026 as the retirement date for gemini-2.5-flash, gemini-2.5-pro and gemini-2.5-flash-lite. On the Gemini Developer API, Google deprecated gemini-2.5-flash and gemini-2.5-pro on November 2, 2026, limits them to projects that have already used them, and from December 1, 2026 routes their requests to gemini-3.5-flash-lite and gemini-3.8-flash. gemini-2.5-flash-lite is not deprecated there and has no shutdown date.

What happens when a Gemini model is shut down? Usually the endpoint is turned off and requests to that model ID fail. Google documents no automatic redirect for the 2.5 models on Vertex. The exceptions are on the Gemini API, which routes gemini-3.5-flash to gemini-3.6-flash and gemini-3.7-flash to gemini-3.8-flash, and from December 1, 2026 routes gemini-2.5-pro to gemini-3.8-flash and gemini-2.5-flash to gemini-3.5-flash-lite, billed at the new model's rates.

How much notice does Google give before retiring a Gemini model? On Vertex, models in the standard table are available for at least 12 months after release. Shorter-lived models get a fixed retirement date at least 45 days ahead, and dates are never moved earlier. On the Gemini API, listed dates are the earliest possible shutdown, and -latest aliases get two weeks' email notice before the version behind them changes.

What should replace Gemini 2.5 Pro? Vertex lists gemini-3.8-flash or gemini-3.5-flash. If you need Pro-class reasoning, the options are gemini-3.1-pro-preview, which is still a preview, or a Gemini 4 model: gemini-4-carbon, which Google calls its strongest reasoning model, or the faster gemini-4-argon. Replay real traffic on whichever you pick: a Flash model replacing a Pro one is the swap most likely to change behavior on hard cases.

Should I use gemini-flash-latest to avoid future deprecations? No. A -latest alias is hot-swapped with every new release, so it trades one planned migration for many untested ones. Pin a version and run the migration checklist when its date comes.

Keep reading