EmbeddingGemma 2
Google DeepMind's open embedding model, built on the Gemma 4 architecture. It maps text, code, images, video and audio into one shared vector space - small enough to run on a phone, and free to use under Apache 2.0.
740M parameters · 768 dimensions · 8K context · 100+ languages
What is EmbeddingGemma 2?
An embedding model does not write answers. It converts content into a list of numbers - a vector - so that things with similar meaning end up close together. That is the engine behind semantic search, recommendations and retrieval for RAG.
One space, five formats
Text, code, images, video and audio all land in the same 768-dimension space, so a typed query can find a photo, a clip or a recording.
Built for devices
Google reports about 567 MB of RAM for the full model on a Pixel 11 Pro with quantisation, and about 191 MB text-only.
Modular
A 270M text and code core with optional vision (170M) and audio (300M) encoders. Load only the parts you need.
Open
Open weights under Apache 2.0 on Hugging Face and Kaggle. It shares its tokenizer and audio encoder with Gemma 4.
EmbeddingGemma 2 vs the original
Version 1 was a text-only model. Version 2 adds four more input types, a longer context and much better code retrieval.
| EmbeddingGemma 2 | EmbeddingGemma (v1) | |
|---|---|---|
| Released | October 6, 2026 | September 4, 2025 |
| Inputs | Text, code, images, video, audio | Text only |
| Parameters | 740M (270M text-only) | 308M |
| Context | 8,192 tokens | 2K tokens |
| Output | 768 dimensions; 512, 256, 128 by truncation | 768 dimensions; 512, 256, 128 by truncation |
| MTEB Code | 78.68 | 68.76 |
| Languages | 100+ | 100+ |
| Built on | Gemma 4 architecture | Gemma 3 |
From Google's EmbeddingGemma overview and launch post. Vectors from the two versions are not interchangeable - if you upgrade, re-embed your data.
Download EmbeddingGemma 2
Free weights from Hugging Face or Kaggle. Google says availability in its Gemini Enterprise Agent Platform Model Garden is coming soon.
| Source | What you get | Link |
|---|---|---|
| Hugging Face | Official weights and model card | google/embeddinggemma-2 |
| Hugging Face collection | The release collection | EmbeddingGemma 2 collection |
| Kaggle | Same weights, with free notebooks | Kaggle model page |
| Model card | Specs, benchmarks and prompts | Google's v2 model card |
| Get started guide | Text embeddings with sentence-transformers | Google's guide |
| Multimodal guide | Images, audio and video | Google's guide |
| Fine-tuning guides | Text and vision tuning | Google's guide |
| Announcement | Google's launch post, October 6, 2026 | Read the announcement |
From a terminal: hf download google/embeddinggemma-2
Your first embeddings
The examples use the sentence-transformers library, as in Google's guides.
# pip install -U sentence-transformers transformers from sentence_transformers import SentenceTransformer model = SentenceTransformer("google/embeddinggemma-2") query = "What causes the northern lights?" document = "The northern lights are caused by charged particles from the sun." query_emb = model.encode(query, prompt_name="SearchQuery") doc_emb = model.encode(document, prompt_name="Document") print(model.similarity(query_emb, doc_emb))
# pip install -U sentence-transformers transformers pillow soundfile torchcodec # Pass a dict naming the input type; values can be URLs or local files emb_image = model.encode({"image": img_url}) emb_audio = model.encode({"audio": aud_url}) emb_video = model.encode({"video": vid_url}) # Everything lives in one space, so compare across types directly scores = model.similarity(emb_image, emb_candidates)[0]
# One embedding for several inputs at once query_multimodal = { "text": "Landmark and interior photos with spoken narration", "image": [img_url, example_img_url], "audio": aud_url, } emb_multimodal = model.encode(query_multimodal)
# Skip an encoder you do not need to save memory. # This drops the vision encoder, leaving text and audio: model = SentenceTransformer( "google/embeddinggemma-2", config_kwargs={"vision_config": None}, )
Samples from Google's model card and multimodal guide.
float16. Use bfloat16 or float32 instead.Technical specs
| Parameters | 740M total |
| Layers | 24 |
| Output | 768 dimensions; 512, 256 or 128 by truncation |
| Context | 8,192 tokens, shared across all inputs |
| Vocabulary | 262,144 tokens |
| Languages | 100+ |
| License | Apache 2.0 |
| Configuration | Parameters |
|---|---|
| Text and code only | 270M |
| Text + images | 440M |
| Text + audio | 570M |
| Everything | 740M |
How much fits in one input
Text
8,192 tokens - four times version 1.
Images
About 29 images, at the default 280 tokens each.
Video
About 58 frames, at 140 tokens per frame and one frame per second.
Audio
About 327 seconds (5.5 minutes), mono at 16 kHz.
From Google's model card. The limits are alternatives, not additive: all inputs share the same 8,192-token budget, so split long recordings into segments.
Tell it what the text is for
For text, EmbeddingGemma 2 expects a short task prefix. Pass the prompt name and sentence-transformers adds it for you. Google notes that leaving it out can lower quality.
| Use case | Prompt name | Prefix it adds |
|---|---|---|
| Web search | SearchQuery | task: search result | query: {query} |
| Question answering | QuestionAnswering | task: question answering | query: {question} |
| Fact checking | FactChecking | task: fact checking | query: {claim} |
| Code search | CodeRetrieval | task: code retrieval | query: {query} |
| Classification | Classification | task: classification | query: {content} |
| Clustering | Clustering | task: clustering | query: {content} |
| Sentence similarity | SentenceSimilarity | task: sentence similarity | query: {content} |
Search, question answering, fact checking and code search are asymmetric: embed queries with the prompt above and
the content being searched with prompt_name="Document". Classification, clustering and similarity use the same
prompt on both sides.
How it scores
Google describes it as best-in-class for its size on the MTEB Code and MAEB audio benchmarks. Scores below are at the full 768 dimensions.
Code retrieval jumped
MTEB Code rose from 68.76 on version 1 to 78.68 - a gain of almost ten points.
Shorter vectors hold up
Google reports little loss at 512 or 256 dimensions, which can cut vector storage by up to six times at 128.
128 has a cost
At 128 dimensions Google reports a substantial drop on multimodal tasks. Test before committing to it.
Source: Google's model card and launch post. These are Google's own published figures.
What people build with it
On-device RAG
EmbeddingGemma 2 finds the relevant passages; a Gemma 4 model writes the answer. Both run locally.
Media library search
Type a description, or speak one, and find the matching photo, video moment or recording.
Audio search
Search voice memos and recordings by text without transcribing them first.
Classification and routing
Sort incoming content or requests into categories quickly, without calling a large model.
Clustering
Group similar documents, images or clips to explore or de-duplicate a collection.
Works with
Tools named in Google's launch post. Support in each one may arrive on its own schedule - check the tool's own listing for an EmbeddingGemma 2 build before relying on it.
Know before you build
It does not generate
It produces vectors only. For chat or text generation you need a Gemma 4 model alongside it.
Languages vary
Quality is not equal across the 100+ supported languages. Test on your own.
Bias
Trained on large real-world text and image data, it can reflect the biases in that data.
Safeguards are yours
Google expects developers to add application-level safeguards. See safety.
EmbeddingGemma 2 questions
Can EmbeddingGemma 2 chat or answer questions?
No. It turns content into vectors for search and comparison. To answer questions, pair it with a generative model such as Gemma 4: EmbeddingGemma 2 retrieves, Gemma 4 writes.
Is it free for commercial use?
Yes. It is released under Apache 2.0, which permits commercial use, modification and redistribution.
Should I upgrade from the original EmbeddingGemma?
If you need images, audio, video, longer inputs or better code search, yes. For short, text-only workloads version 1 is smaller at 308M parameters - though version 2's text-only configuration is smaller still at 270M. Either way, plan to re-embed your data, because the two versions produce different vector spaces.
Which vector size should I use?
Start with 768. Drop to 512 or 256 if storage or speed matters; Google reports little quality loss there. Use 128 only after testing, especially for images, audio and video.
What hardware does it need?
Very little. Google reports about 567 MB of RAM for the full multimodal model on a Pixel 11 Pro with quantisation, and about 191 MB in text-only mode. It runs on phones, laptops and servers.
How long can audio and video inputs be?
Roughly 5.5 minutes of audio, 58 video frames or 29 images per input, all drawn from the same 8,192-token budget. Split longer media into segments and embed each one.
Can I fine-tune it?
Yes. Google publishes fine-tuning guides for text and for vision, and its launch post points to Unsloth for fine-tuning as well.
Add search to anything, on any device
Open weights, five input types, one vector space.