Gemma 4 Playground
A free playground that talks to Gemma 4 running on your own computer. Chat with streaming replies, adjust thinking and sampling, try test prompts, and see EmbeddingGemma 2 rank passages by meaning. Your prompts go from this page straight to your machine and nowhere else.
Needs Ollama on your computer · no account, no API key · nothing is stored ·
Three steps before you start
The playground has no model of its own. It connects to Ollama on your computer, so that needs to be running first.
Install Ollama
From ollama.com/download. Full instructions are in the install guide and on the Ollama page.
Download the models
ollama pull gemma4:12b-it-qat # chat model, 7.2 GB (use gemma4:e4b-it-qat on 8 GB) ollama pull embeddinggemma-2 # search model, 1.3 GB (optional)
Allow this site to talk to Ollama
For safety, Ollama ignores requests from websites unless you allow them. Allow only this site, then restart Ollama.
launchctl setenv OLLAMA_ORIGINS "https://gemmai4.com" # then quit Ollama from the menu bar and open it againsetx OLLAMA_ORIGINS "https://gemmai4.com" :: then quit Ollama from the system tray and open it again
sudo systemctl edit ollama # add these two lines, save, then restart: # [Service] # Environment="OLLAMA_ORIGINS=https://gemmai4.com" sudo systemctl restart ollama
*. Some guides suggest OLLAMA_ORIGINS="*". That lets any website you visit use your local models. Name this site only, as shown.Your browser may also ask for permission to reach devices on your local network; allow it for this page. If you open the page from a saved file instead of the website, see the FAQ.
Chat playground
Pick a model, type a message, press Enter. Use Shift + Enter for a new line.
The sliders start at Google's recommended values for Gemma 4: temperature 1.0, top-p 0.95, top-k 64. The conversation lives only in this page and is gone when you reload. Reasoning from earlier turns is not sent back to the model, as Google's guidance recommends.
EmbeddingGemma 2 search tester
EmbeddingGemma 2 does not chat. It turns text into vectors so things can be found by meaning. Type a query and a few passages, and it ranks the passages from closest to furthest - even when they share no words with the query.
What the score means
It is the cosine similarity between two vectors: closer to 1 means closer in meaning. Compare scores within one run, not across models.
Text only here
The model also embeds images, audio and video, but this tester sends text. For media, use Python as shown in how to use.
From tester to search
Real search works the same way: embed your documents once, embed each query, and return the closest. Add Gemma 4 to write the answer.
The tester calls Ollama's /api/embed endpoint on your machine. Google recommends adding a short task label to text for best quality; this tester sends your text as written, to keep things simple.
How to drive it well
Turn thinking on for hard problems
Maths, logic and multi-step questions benefit. For quick chat it only adds waiting.
Start from Google's settings
Temperature 1.0, top-p 0.95, top-k 64. Lower the temperature if you want steadier, more repeatable answers.
Use the system prompt
Set the role, tone and format once. Gemma 4 has a real system role and follows it.
Watch the context length
Raise it for long documents. Higher values use more memory, so step up gradually.
Compare fairly
When comparing two model sizes, keep every setting the same and reuse the same prompts.
Try the stress tests
Ask about last week's news, or for an exact one-word reply. They show the knowledge cutoff and how well it follows instructions.
More technique in prompting and capabilities; what to expect from each size is on benchmarks and the models page; known gaps are under limitations.
Places to try both models online
If you cannot run Ollama, these need nothing installed. Your prompts are processed on someone else's servers, so keep private material out.
| Where | What you can try | Needs |
|---|---|---|
| Google AI Studio | Gemma 4 31B and 26B A4B, with images and system instructions | A Google account |
| OpenRouter | Gemma 4 31B and 26B A4B through several hosts | An account; pay per token |
| Embedding Draw Challenge | EmbeddingGemma 2: draw an object and it guesses what you are drawing | A browser |
| EmbeddingGemma 2 WebGPU demo | EmbeddingGemma 2 running inside your browser | A browser with WebGPU |
| Google AI Edge Gallery | Gemma 4 E2B and E4B on a phone, plus EmbeddingGemma 2 media search demos | The phone app |
| Kaggle | Both models in free notebooks | A Kaggle account |
Demo links from Google's developer guide and launch post; the demos were not tried for this page. More ways to chat are on the chat page; hosted prices on pricing; phones in mobile downloads and on the Android page; programmatic access on the API page.
Where your prompts go
To your own machine
The playground sends each request from your browser directly to the Ollama address shown, which is your own computer by default.
Not to this site
The page has no server of its own for prompts. It does not receive, log or store what you type or what the model answers.
Nothing is kept
The conversation is held in the page's memory only. Reloading or closing the tab clears it.
The page itself loads like any other page on this site, which may involve analytics and advertising scripts; those do not see your prompts. If you change the server address to another computer, your prompts go to that computer instead. See safety.
It says "Not connected". What should I check?
First, that Ollama is running: ollama list in a terminal should answer. Second, that you allowed this site with OLLAMA_ORIGINS and restarted Ollama afterwards. Third, that your browser has not blocked access to your local network. Then press Connect.
Why do I have to set OLLAMA_ORIGINS?
Browsers stop websites from talking to programs on your computer unless that program agrees. The setting tells Ollama to accept requests from this site.
Is the playground free?
Yes. The page is free, Ollama is free, and both models are open under Apache 2.0. The computing is done by your own machine.
It is very slow. Why?
The model is probably too large for your memory. Try gemma4:e4b-it-qat, lower the context length, or turn thinking off. See the VRAM guide and QAT builds.
Does it keep my conversation?
No. Everything is held in the page for the current visit only.
Can I use it with something other than Ollama?
Any server that offers Ollama's /api/tags, /api/chat and /api/embed endpoints will work if you change the address. For LM Studio and other tools, use their own chat windows.
Can I use the page from a saved file?
Yes, but a saved file has no website address for Ollama to allow. Using the page on this site with the setting shown is simpler and safer.
Which model should I pick?
The 12B on a 16 GB machine, E4B on 8 GB. Compare sizes in the model comparison, pick a runtime with the runtime selector, and see features for what each can do.
Not set up yet?
Install Ollama, pull a model and come back. It takes about ten minutes.