Gemma 4 / Models / EmbeddingGemma 2
Released October 6, 2026New

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

Text Image Audio Video Embedding Gemma 2 one shared vector space query
Different formats, same meaning, neighbouring points.
Overview

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.

What's new

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 2EmbeddingGemma (v1)
ReleasedOctober 6, 2026September 4, 2025
InputsText, code, images, video, audioText only
Parameters740M (270M text-only)308M
Context8,192 tokens2K tokens
Output768 dimensions; 512, 256, 128 by truncation768 dimensions; 512, 256, 128 by truncation
MTEB Code78.6868.76
Languages100+100+
Built onGemma 4 architectureGemma 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

Download EmbeddingGemma 2

Free weights from Hugging Face or Kaggle. Google says availability in its Gemini Enterprise Agent Platform Model Garden is coming soon.

SourceWhat you getLink
Hugging FaceOfficial weights and model cardgoogle/embeddinggemma-2
Hugging Face collectionThe release collectionEmbeddingGemma 2 collection
KaggleSame weights, with free notebooksKaggle model page
Model cardSpecs, benchmarks and promptsGoogle's v2 model card
Get started guideText embeddings with sentence-transformersGoogle's guide
Multimodal guideImages, audio and videoGoogle's guide
Fine-tuning guidesText and vision tuningGoogle's guide
AnnouncementGoogle's launch post, October 6, 2026Read the announcement

From a terminal: hf download google/embeddinggemma-2

Quick start

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.

Do not use float16. Google warns that the model's activations are incompatible with float16. Use bfloat16 or float32 instead.
Specifications

Technical specs

Parameters740M total
Layers24
Output768 dimensions; 512, 256 or 128 by truncation
Context8,192 tokens, shared across all inputs
Vocabulary262,144 tokens
Languages100+
LicenseApache 2.0
ConfigurationParameters
Text and code only270M
Text + images440M
Text + audio570M
Everything740M

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.

Task prompts

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 casePrompt namePrefix it adds
Web searchSearchQuerytask: search result | query: {query}
Question answeringQuestionAnsweringtask: question answering | query: {question}
Fact checkingFactCheckingtask: fact checking | query: {claim}
Code searchCodeRetrievaltask: code retrieval | query: {query}
ClassificationClassificationtask: classification | query: {content}
ClusteringClusteringtask: clustering | query: {content}
Sentence similaritySentenceSimilaritytask: 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.

Benchmarks

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.

61.36MTEB Multilingual v2
78.68MTEB Code (NDCG@10)
64.64Images (MIEB lite)
67.84Visual docs (MMEB v2)
50.67Video (MMEB v2, Hit@1)
69.54Audio (MSEB, MRR@10)

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.

Use cases

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.

💻

Code search

Index a codebase locally for semantic search and for retrieval inside coding agents.

🎙️

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

sentence-transformersTransformersllama.cppOllamaLM StudioMLXvLLMSGLangLiteRTMediaPipeTransformers.jsWebGPUQdrantUnsloth

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.

Limitations

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.

FAQ

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.

Top