NanoBanana - Text Gen + URL Context
The Gemini node that actually reads the page you paste a link to
- network
- text
The annoying little job it solves
You have a link. A model card, a release note, a spec sheet, an article you're building a prompt around. You want its contents as text inside your graph, and copy-pasting the whole page into a text widget is miserable.
NanoBanana_TextGenURL is the pack's tool-using text node. You paste URLs into the prompt, and Google's URL Context tool fetches and reads those pages before the model answers. There's also a google_search toggle if you'd rather the model go find pages on its own than only read the ones you handed it.
Where this fits matters, because the KB's usual advice for an LLM in the graph is "run a small local abliterated model - free and uncensored." This node comes at it from the opposite end. It's the API path, and the reason to pick it is the one thing a local 8B can't do: read the live web. Scrape a changelog, pull current numbers off a vendor page, summarize release notes, then feed the output into whichever text encode node your workflow already uses.
How it works
It's a thin, honest wrapper - no mystery. The node sends your prompt plus a tools list (url_context, and google_search if you flipped it) to client.interactions.create() over Google's Interactions API, then returns output_text. The cap is up to 20 URLs in the prompt, and this node is one of the four in the pack whose request shapes the test suite checks against a fake client.
Read the author's docstring before you get annoyed at it, because it's a list of what URL Context won't touch: paywalled pages, YouTube, Google Workspace files, and audio/video files. It reads HTML and text - that's the whole trick. If your link resolves to a PDF, this isn't your node; Files Upload → Ask Uploaded File is the pack's path for that.
Inputs and outputs
Three required. api_key, model (defaults to gemini-3.8-flash, with 34 options from the gemini-pro-latest aliases down through the Gemma models - the pack's Model Selector node helps if that list glazes your eyes), and prompt, whose tooltip is literally "Prompt containing the URLs to read." No separate URL field: paste the link inline, as in Read https://... and tell me which models it deprecates.
The optional ones are where you steer it:
system_instruction- the biggest quality lever here. "Answer only from the pages, quote the line you're basing it on" cuts the confident-nonsense rate a lot.google_search- off by default. Turn it on and the model can search past your links instead of being fenced to them.custom_model- override field, for the next thing Google ships.network- the pack's Network Route node, if egress needs to come from a particular region.
Output is one thing: text, a STRING. Wire it into anything that takes a prompt string - a CLIPTextEncode, the pack's Prompt Refiner, a save-text node.
Note what isn't here: no temperature, no top_p, no seed, no thinking budget. If you want knobs, the pack's plain Text Generation node has them. This one is deliberately "read these pages and answer." On Gemini 3.x Google deprecated temperature/top_p/top_k anyway, so you're not giving up much.
Installing it
Same pack as everything else here, so the steps don't change. ComfyUI Manager: search NanoBanana2, install, restart. Or:
cd ComfyUI/custom_nodes
git clone https://github.com/IxMxAMAR/ComfyUI-NanoBanana2
pip install "google-genai>=2.3.0"
No model downloads, no GBs of weights - the whole pack is an HTTP client. You need a Google AI Studio key (aistudio.google.com → Get API Key): paste it into the password-masked field or export GEMINI_API_KEY and leave the field empty. The google-genai >= 2.3.0 floor is required, since it's the release that exposes the output_text helper on Interactions responses.
Where people get burned
- Nothing validates your URLs. You get the model's behavior, which ranges from a clean summary to a shrug. If it says it can't access the page, suspect a login wall, a JavaScript-rendered page, or one of the unsupported types above - not the node.
- "Up to 20 URLs" is a ceiling, not a target. Twelve links in one prompt gives you a mushier answer and a slower call. Two or three, with a specific question, is better.
- It's a remote call with your key in it. Standard API-node hygiene applies: this is arbitrary Python that holds a credential and calls the network by design - the exact shape of the category that already got weaponized once in this ecosystem. Install from the official repo via Manager, not a random mirror.
- Every run is a fresh billed call, including identical inputs - this pack re-executes on every queue on purpose. If you're looping it over a hundred prompts to survey a docs site, price it first; the pack ships a Cost Estimator node for exactly that.
For a job that used to mean scraping by hand or pasting chunks of a page into a prompt widget, having it as a node you can wire into the graph is quietly useful. The honest limitation is in the name: it reads web pages - not PDFs, not videos, not anything behind a login.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| api_key | STRING | — | |
| model | COMBO | gemini-3.8-flash | 34 options: gemini-pro-latest, gemini-flash-latest, gemini-flash-lite-latest, gemini-3.8-flash, gemini-3.7-flash, gemini-3.6-flash, +28 |
| prompt | STRING | Prompt containing the URLs to read. | |
| custom_modelopt | STRING | — | |
| system_instructionopt | STRING | — | |
| google_searchopt | BOOLEAN | false | Also enable Google Search grounding. |
| networkopt | NB_NETWORK | Optional. Wire a NanoBanana - Network Route node here to route this request through that proxy (e.g. US egress). |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| text | STRING | — |