Updated 2026-11-19. Gemini 4 Neon went generally available on 2026-11-18 at $3.00 per million input tokens and $15.00 per million output tokens, paid tier only, with four thinking levels and one 1,048,576-token window shared by input, thinking and output. Migrating from another Gemini 4 model means changing one field.
# Copy-paste starter: call it on the Interactions API. curl "https://generativelanguage.googleapis.com/v1beta/interactions" \ -H "x-goog-api-key: $GEMINI_API_KEY" -H 'Content-Type: application/json' -X POST \ -d '{"model":"gemini-4-neon","input":"Build a single-file HTML rate-limiter simulator."}'
The default thinking level is high, so that request is already the balanced setting rather than a cheap one. Add "generation_config": {"thinking_level": "low"} to the JSON when you want the cheap one.
high
"generation_config": {"thinking_level": "low"}
The family now has four rungs, and the page names Neon as the one for high-frequency complex tasks [1][2].
gemini-4-hydrogen
low
medium
xhigh
gemini-4-neon
gemini-4-carbon
gemini-4-argon
gemini-3.8-flash
Three details on that table decide more work than the model choice does. Neon is paid tier only, so a project on the free tier gets an error rather than a slower answer. Neon defaults to high where Carbon and Argon default to medium, so a straight model-id swap raises your token bill before you change anything else. And xhigh exists only on Neon and Hydrogen, so removing a level from your settings is part of the migration in the other direction.
Neon accepts text, images, video, audio and PDF, and returns text. Its code execution capability means it will write and run code on your behalf, which is useful and is also where agent-written code breaks in ways a review would have caught. Its capability list includes code execution, computer use, function calling, file search, grounding, agentic video understanding and audio generation. One line in that list matters for a migration: explicit caching is not supported [1]. Implicit caching is where the discount comes from instead, and it takes 95 percent off cached input, which puts cached input at $0.15 per million tokens [3].
This is the control that moves cost and latency most, and the field is thinking_level inside generation_config [2][4].
thinking_level
generation_config
Google's own advice is to start at high and reserve xhigh for problems where high falls short, and to run your evaluations at all four levels with a high max_output_tokens so the comparison is not cut off by a cap [2].
max_output_tokens
from google import genai client = genai.Client() interaction = client.interactions.create( model="gemini-4-neon", input="Audit this payment retry queue for race conditions and rewrite the lock acquisition logic.", generation_config={"thinking_level": "xhigh"}, ) print(interaction.output_text)
Thinking tokens are billed as output. The pricing page states that every token the model processes is counted, including thinking tokens and the internal tool system instructions and function declarations used by grounding, all at the $15.00 output rate [3]. The usage block in the thinking guide carries a field named total_thought_tokens alongside total_input_tokens and total_output_tokens, so the split is visible per response if you log it [4]:
total_thought_tokens
total_input_tokens
total_output_tokens
{"usage": {"total_tokens": 530, "total_input_tokens": 62, "total_output_tokens": 171, "total_thought_tokens": 297}}
That example is worth reading twice. Of 530 tokens in the response, 297 were thinking, which is more than the answer itself, and all 297 bill at the output rate. The same accounting distorts the cost of unattended agent work, where nobody is watching a single answer. A team that measures its Gemini spend from the visible answer will undercount it substantially. I made the same point about reasoning tokens in the GPT-6.2 guide, and it holds here with a documented number rather than an inference.
The documented quickstart uses the Interactions API, and the model page notes that both generateContent and the Interactions API are available [1][2].
generateContent
from google import genai client = genai.Client() interaction = client.interactions.create( model="gemini-4-neon", input="Build an interactive single-file HTML token bucket rate-limiter simulator with live sliders for burst size and request traffic." ) print(interaction.output_text)
import { GoogleGenAI } from "@google/genai"; const client = new GoogleGenAI({}); const interaction = await client.interactions.create({ model: "gemini-4-neon", input: "Build an interactive single-file HTML token bucket rate-limiter simulator with live sliders for burst size and request traffic.", }); console.log(interaction.output_text);
I sent an unauthenticated request to the API from this machine to capture what a misconfigured deployment actually receives, rather than what the docs say it receives. Google answered HTTP 403, not 401:
{ "error": { "code": 403, "message": "Permission denied on the service.", "status": "PERMISSION_DENIED", "details": [ { "@type": "type.googleapis.com/google.rpc.ErrorInfo", "reason": "ACCESS_DENIED", "domain": "googleapis.com", "metadata": { "service": "generativelanguage.googleapis.com" } } ] } }
The same body comes back from GET /v1beta/models with no key, which is the quickest way to tell a missing key apart from a missing model: if listing models is denied, the credential never arrived. Engineers who pattern-match on 401 from other vendors read this 403 as a permissions problem on their project and go looking in the wrong place.
GET /v1beta/models
Three numbers govern output, and they are easy to conflate [1][2]:
background: true
The max_output_tokens field caps thinking and output together, which is the trap. A cap of 8,192 that felt generous on an older model now has to cover the reasoning as well as the answer, so a request that thinks heavily can return a truncated final answer while reporting success. The migration guidance says to raise hardcoded low caps to 65,536, or lower the thinking level instead of leaving the cap where it was [2].
import time from google import genai client = genai.Client() interaction = client.interactions.create( model="gemini-4-neon", input="Generate a complete multi-module migration specification and test suite for this service.", background=True, generation_config={"max_output_tokens": 262144}, ) while interaction.status == "in_progress": time.sleep(5) interaction = client.interactions.get(interaction.id) print(interaction.output_text)
Those are the starting values the docs recommend: keep the 65,536 default for standard tasks, and set background to true with 131,072 or 262,144 for long outputs and multi-step work [2]. On the older Gemini 3.8 Flash the input and output budgets were separate, so code written against it needed a cap that is now wrong in a way that only shows up on long answers.
background
A model-id swap is one line, and the four things that break are all elsewhere in the code. I wrote a small script that walks a repository and reports them, then ran it against a scratch app containing the exact mistakes this migration punishes.
#!/usr/bin/env python3 """Audit a repo for the things a Gemini 4 Neon migration breaks.""" import pathlib, re, sys CODE = [ (re.compile(r'model\s*[:=]\s*["\'](gemini-(?:3[^"\']*|4-(?:argon|carbon|hydrogen)))["\']'), "model id", "set the model id to gemini-4-neon", None), (re.compile(r'thinking_?[Ll]evel["\']?\s*[:=]\s*["\']minimal["\']'), "thinking level", "minimal is rejected by Neon; use low, medium, high or xhigh", None), (re.compile(r'max_?[Oo]utput_?[Tt]okens["\']?\s*[:=]\s*(\d+)'), "output cap", "one 1M window now; raise the cap to 65536 or lower the thinking level", 65536), (re.compile(r'caches\.create|cached_content'), "explicit cache", "not supported on Neon; implicit caching gives the discount", None), ] DOCS = [(re.compile(r'gemini-(?:3[^"\'\s]*|4-(?:argon|carbon|hydrogen))'), "doc mention", "check prose that names the old model", None)] CODE_EXT = {".py", ".js", ".ts", ".tsx", ".go", ".java", ".rb"} DOC_EXT = {".md", ".yaml", ".yml", ".json"} SELF = {pathlib.Path(__file__).name} def main(root): root_path = pathlib.Path(root) hits, seen = [], 0 for path in sorted(root_path.rglob("*")): if not path.is_file() or path.name in SELF: continue if path.suffix not in CODE_EXT | DOC_EXT: continue seen += 1 rules = CODE + DOCS if path.suffix in CODE_EXT else DOCS for n, line in enumerate(path.read_text(errors="ignore").splitlines(), 1): for pattern, kind, action, below in rules: m = pattern.search(line) if not m: continue # a numeric floor, so a cap that is already large enough is not reported if below is not None and int(m.group(1)) >= below: continue hits.append((str(path.relative_to(root_path)), n, kind, action, line.strip()[:56])) for f, n, kind, action, snip in hits: print(f"{f}:{n} {kind:<15} {action}\n {snip}") kinds = sorted({h[2] for h in hits}) print(f"\n{len(hits)} finding(s) across {seen} scanned file(s); kinds: {', '.join(kinds) or 'none'}") return 0 if not hits else 1 if __name__ == "__main__": sys.exit(main(sys.argv[1] if len(sys.argv) > 1 else "."))
Two of its rules were wrong until I ran it, and both bugs are worth knowing about because you will write them too.
The first version flagged its own source file, because the pattern that looks for explicit caching is the same text the pattern is written in. The fix is the SELF set. The first version also missed "thinking_level": "minimal" in a Python dictionary, because the pattern expected a colon straight after the field name and the key had a closing quote in between, so it matched an assignment but not a quoted key. Allowing an optional quote before the separator found it.
SELF
"thinking_level": "minimal"
The third bug was the interesting one. A rule that flags any max_output_tokens value flags the corrected value as well, so a migrated repo never comes back clean. That is why the pattern captures the number and compares it, and why the tuple carries a below field: detection is not the same as judgement.
below
Run against the broken copy, the audit reports this, and the exit code is 1 so a pipeline can gate on it:
$ python3 audit.py /tmp/g4lab app/chat.py:6 model id set the model id to gemini-4-neon model="gemini-3.8-flash", app/chat.py:6 doc mention check prose that names the old model model="gemini-3.8-flash", app/chat.py:8 thinking level minimal is rejected by Neon; use low, medium, high or xhigh config={"max_output_tokens": 8192, "thinking_level": "mi app/chat.py:8 output cap one 1M window now; raise the cap to 65536 or lower the thinking level config={"max_output_tokens": 8192, "thinking_level": "mi app/notes.md:1 doc mention check prose that names the old model Runbook: the assistant uses gemini-4-carbon for triage. app/summarise.ts:5 model id set the model id to gemini-4-neon model: "gemini-4-hydrogen", app/summarise.ts:5 doc mention check prose that names the old model model: "gemini-4-hydrogen", app/summarise.ts:7 output cap one 1M window now; raise the cap to 65536 or lower the thinking level config: { maxOutputTokens: 4096, thinkingLevel: "medium" workers/batch.py:3 model id set the model id to gemini-4-neon cache = client.caches.create(model="gemini-3.8-flash", c workers/batch.py:3 explicit cache not supported on Neon; implicit caching gives the discount cache = client.caches.create(model="gemini-3.8-flash", c workers/batch.py:3 doc mention check prose that names the old model cache = client.caches.create(model="gemini-3.8-flash", c workers/batch.py:4 model id set the model id to gemini-4-neon res = client.models.generate_content(model="gemini-3.8-f workers/batch.py:4 explicit cache not supported on Neon; implicit caching gives the discount res = client.models.generate_content(model="gemini-3.8-f workers/batch.py:4 doc mention check prose that names the old model res = client.models.generate_content(model="gemini-3.8-f 14 finding(s) across 4 scanned file(s); kinds: doc mention, explicit cache, model id, output cap, thinking level $ echo $? 1
After the four edits the audit describes, the same command on the migrated copy reports nothing and exits 0, which is the property you want in a migration check:
$ python3 audit.py /tmp/g4lab_fixed 0 finding(s) across 4 scanned file(s); kinds: none $ echo $? 0
The doc mention findings are there because prose counts. Runbook: the assistant uses gemini-4-carbon for triage is not code, and it is exactly the line that survives a migration and then misleads the next person on call.
doc mention
Runbook: the assistant uses gemini-4-carbon for triage
From another Gemini 4 model, no request schema changes are needed [2]. Set model to gemini-4-neon, check your thinking defaults because Carbon and Argon default to medium while Neon defaults to high, and use a paid tier project.
model
From Gemini 3 or earlier, four things change. The model id. The context accounting, because Gemini 3.8 Flash separated a 1M input budget from a 64K output budget while Neon shares one 1,048,576-token window across input, thinking and output. The thinking configuration, because Neon adds xhigh and rejects minimal with an error, which the Gemini 3.8 documentation accepted. And the caching strategy, because explicit caching is out.
minimal
If you use a coding agent that supports skills, the docs publish a migration skill rather than a checklist to follow by hand [6]. On the Anthropic side, the equivalent surface was changing this week, which I track in the Code Mode guide:
/gemini-api-dev migrate my app to Gemini 4 Neon
Is Gemini 4 Neon free to try on the free tier? No. It is paid tier only, and the docs say so plainly, so an evaluation has to run on a billing-enabled project.
What does a straight swap from Gemini 4 Carbon cost me? More, in two ways. Carbon defaults to medium thinking and Neon defaults to high, and Neon's per-token price sits above Carbon's, so the same prompt uses more tokens at a higher rate. Set thinking_level to medium during a migration if you want the old behaviour.
Why is my answer truncated with no error? Because max_output_tokens caps thinking and output together and the default is 65,536 per hop. If your code still sets 8,192 from an older integration, the thinking consumed the budget. Raise the cap or lower the thinking level.
Can I use explicit caching with Neon? No, it is not supported. Implicit caching applies the discount automatically, at 95 percent off cached input tokens [1][3].
What error does thinking_level: "minimal" produce? It is rejected as a request error. I did not reproduce it, because my unauthenticated request was refused at the credential check before any parameter was read, so treat the rejection as documented [2] rather than as observed here.
thinking_level: "minimal"
How does this compare with GPT-6.2? I covered the two OpenAI models in the GPT-6.2 guide, and the older Gemini comparison is in Argon versus Claude Code. The pattern across all of them is the same: measure thinking or reasoning tokens separately from the answer, or your cost model will be wrong in one direction every time.
[1] Google, Gemini 4 Neon model page, fetched 2026-11-19. Source of the model id, the input and output modalities, the context window and per-hop output limits, the capability list, the note that explicit caching is not supported, and the pointer to the what-is-new page.
[2] Google, What's new in Gemini 4 Neon, fetched 2026-11-19. Source of the family positioning, the thinking-level table and guidance, the long decode and background execution behaviour, the output token starting values, and both migration checklists.
[3] Google, Gemini API pricing, fetched 2026-11-19, referenced for the $3.00 input and $15.00 output rates, the flat pricing across the context window, the 95 percent implicit caching discount, and the statement that thinking tokens and grounding declarations are billed.
[4] Google, thinking guide, fetched 2026-11-19, referenced for the thinking_level parameter, the per-model default and supported levels table, and the usage block carrying total_thought_tokens.
[5] Google, Gemini API release notes, fetched 2026-11-19, referenced for the 2026-11-18 general availability entry and its pricing.
[6] Google, coding agent setup and skills, fetched 2026-11-19, referenced for the published migration skill.
The audit script is thirty lines and it caught four classes of problem in a five-file scratch app. If you want the migration run against a real repository, with the thinking levels tuned per route rather than set globally, send a written intake and we will start from your code.
Maxpertise is an AI-native engineering company. We embed native AI engineers inside your team, live in about 10 days. Please enable JavaScript to view the site, or email contact@maxpertise.net.