Czy wolisz polską wersję strony elektroda?
Nie, dziękuję Przekieruj mnie tamHow to use Gemini Nano with Open WebUI?
You cannot use the real, on-device Gemini Nano with Open WebUI as a normal built-in provider. In practice, Open WebUI is designed to connect to either OpenAI-compatible HTTP APIs or custom Functions, while Gemini Nano is exposed through Android AICore / ML Kit GenAI and Chrome’s Prompt API, not as a standard provider REST endpoint. (docs.openwebui.com)
If your goal is simply to use Gemini inside Open WebUI, the supported method is to connect Google’s cloud Gemini API using the OpenAI-compatible base URL below in Admin Settings → Connections → OpenAI: (docs.openwebui.com)
https://generativelanguage.googleapis.com/v1beta/openai
Important: use that URL without a trailing slash, or model discovery can fail. Open WebUI’s current docs state that Gemini model auto-detection works with this endpoint. (docs.openwebui.com)
The core issue is an interface mismatch:
So the engineering answer is:
If you mean actual Gemini Nano
There is no documented native “add provider” path in Open WebUI for it. You would need a custom bridge that converts Open WebUI requests into Android AICore calls or Chrome Prompt API calls. That is feasible only as a custom integration, not as a standard checkbox configuration. This is an inference from the published interfaces of both systems. (docs.openwebui.com)
If you mean “Gemini in Open WebUI”
Then the correct and supported route is Google’s Gemini API via the OpenAI-compatible endpoint. Open WebUI explicitly documents this flow. (docs.openwebui.com)
If you meant “Nano Banana”
Open WebUI’s community Gemini image guide uses labels like “Nano Banana” for certain Gemini image examples, but that is not the same thing as the actual on-device Gemini Nano runtime. (docs.openwebui.com)
URL: https://generativelanguage.googleapis.com/v1beta/openai
API Key: <your Gemini API key>
/models auto-detection. (docs.openwebui.com)If you want to verify the key first, Google documents OpenAI-compatible chat requests like this: (ai.google.dev)
curl "https://generativelanguage.googleapis.com/v1beta/openai/chat/completions" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $GEMINI_API_KEY" \
-d '{
"model": "gemini-3-flash-preview",
"messages": [
{"role": "user", "content": "Hello"}
]
}'
If that works, Open WebUI usually works as well when the same base URL and key are entered correctly. That conclusion is an engineering inference, but it aligns with Open WebUI’s provider model. (ai.google.dev)
Your only realistic path is a custom adapter:
That path is custom engineering work, not a standard Open WebUI configuration. (docs.openwebui.com)
As of May 2026, Open WebUI’s official documentation recommends using Gemini via the Google AI API, specifically through the OpenAI-compatible endpoint. It also states that Gemini model auto-detection works and warns that the URL must be entered without a trailing slash. (docs.openwebui.com)
Open WebUI also has a community-contributed Gemini image-generation guide. That guide is explicitly marked as not supported by the Open WebUI team, so treat it as experimental rather than canonical product behavior. (docs.openwebui.com)
Google’s current official docs continue to position Gemini Nano as an on-device runtime for Android and Chrome integrations, while Open WebUI continues to be centered on provider protocols such as OpenAI-compatible APIs and Functions. (developer.android.com)
A good way to separate the options is this table:
| What you want | Works with Open WebUI directly? | Best method |
|---|---|---|
| Real Gemini Nano on-device | No, not as a native provider | Build a custom bridge / Function |
| Gemini chat models in Open WebUI | Yes | Google AI API via OpenAI-compatible endpoint |
| Gemini image workflows / “Nano Banana” tutorials | Partly, but community/experimental | Follow the Gemini image guide carefully |
| Local private Google-family model | Yes | Use Gemma through Ollama |
This table is synthesized from the official Open WebUI and Google documentation. (docs.openwebui.com)
If your real requirement is local/private inference, the practical substitute is usually Gemma via Ollama, not Gemini Nano. Open WebUI has first-class Ollama support, and Google documents Gemma as an open model family. (docs.openwebui.com)
There is an important privacy distinction:
If you use Functions, Open WebUI warns that they execute arbitrary Python on your server, so you should review code before enabling it. (docs.openwebui.com)
If you use Direct Connections so users can bring their own Gemini API keys, note that this feature is marked experimental, the keys are stored in the browser’s local storage, and the provider must permit browser CORS access. (docs.openwebui.com)
My recommendation depends on your objective:
Admin Settings → Connections → OpenAI → Add Connection
URL: https://generativelanguage.googleapis.com/v1beta/openai
Do not add a trailing slash. (docs.openwebui.com)
Per-user API keys, no server-side key storage
Enable Direct Connections and let each user add the Gemini endpoint personally. This is experimental and depends on CORS behavior. (docs.openwebui.com)
True local/offline deployment
Use Ollama + Gemma, because Open WebUI natively supports Ollama and Gemma is available as an open model family. (docs.openwebui.com)
Actual Gemini Nano research/integration project
Build a custom OpenAI-compatible proxy or Open WebUI Function around Android AICore or Chrome Prompt API access. (docs.openwebui.com)
The phrase “Gemini Nano with Open WebUI” is ambiguous. In many community discussions it really means Gemini cloud models or image-model setups with labels like “Nano Banana,” not the true on-device Gemini Nano runtime. (docs.openwebui.com)
Also, Open WebUI’s official Gemini path is for the Google AI API, not for a local Gemini Nano daemon. So if someone tells you “just add Gemini Nano as a provider,” they are almost certainly referring to a cloud Gemini endpoint or a custom proxy, not a native Open WebUI feature. That conclusion is an inference from the documented connection methods. (docs.openwebui.com)
If you want to go deeper, research these three tracks:
For Open WebUI-side extensibility, review Functions and Direct Connections. (docs.openwebui.com)
https://generativelanguage.googleapis.com/v1beta/openai
with your Gemini API key, no trailing slash. (docs.openwebui.com)
If you want, I can give you a step-by-step setup for your exact case: