Street View Loader
Real Google Street View Photos Inside ComfyUI — No Screenshots, Just an API Call
- image
- metadata
The name is a small lie: this node doesn't load anything from disk. StreetViewLoader is the workhorse of the ru4ls/ComfyUI_StreetView-Loader pack, and it calls Google's Street View Static API over the network. Type a latitude, longitude pair and it returns a clean, UI-free photo of an actual place on Earth - pixel-for-pixel ground truth, no browser tab, no screenshots, no overlay junk.
Why would you want that in ComfyUI? Because text-to-image models are great at imagining "a charming street in Paris" and useless at recreating your street. They blend a thousand streets into an approximation. When you need the background to be recognizably real - your childhood home, a landmark, a favorite travel spot - photographic ground truth is the only way to guarantee it. The README's framing is the right one: use it as a base for ControlNet (stylize a real scene while keeping the exact layout), a background plate, or a consistent real-world test backdrop for LoRAs and IP-Adapter.
How it works
The node builds a request to https://maps.googleapis.com/maps/api/streetview with your location, heading, pitch, fov, a pixel size, and your API key, then converts the response bytes into a ComfyUI IMAGE tensor. Nothing runs locally; every call counts against your Google Cloud monthly credit (free tier is a generous $200/month - plenty for personal use).
The hard constraint to know up front: the API caps every request at 640x640 pixels. That's why this node gives you aspect-ratio presets instead of width/height boxes - each preset is a real size the API will honor, like "16:9 Widescreen (640x360)".
The inputs that matter
location- a"lat,lon"string. The default is a spot near Katz's Deli in NYC, fine to leave until you have a real target.heading(0–360) - compass direction the camera faces.pitch(−90 to 90) - tilt up or down.fov(10–120) - zoom in or out. These three are the "camera" and take seconds to dial in.aspect_ratio- the dropdown; it silently sets the pixel size.historical_date_id(optional) - a panorama ID for a past capture. When filled, it overrides the location, so you can pull, say, the 2015 view of a block that's been rebuilt since.
Outputs are image (an IMAGE, wire it anywhere an image is expected) and metadata (a STRING containing the full request URL - genuinely handy when a call fails and you want to paste the URL into a browser to see what Google returned).
Installing and getting a key
Install the usual way:
cd ComfyUI/custom_nodes/
git clone https://github.com/ru4ls/ComfyUI_StreetView-Loader.git
cd ComfyUI_StreetView-Loader
pip install -r requirements.txt
…then fully restart ComfyUI. The requirements are light - requests and python-dotenv - so no model downloads and no GPU footprint. ComfyUI Manager finds it if you search the pack title, "ComfyUI Street View Loader Node". The nodes live under the Ru4ls/StreetView menu category.
The one annoying bit is the API key, and there's no skipping it. In Google Cloud Console: create a project, enable the Street View Static API, create a key, and - do this - restrict that key to the Street View Static API so a leaked key can't bill you for other Google services. Then create .env in the custom_nodes/ComfyUI_StreetView-Loader/ folder (a .env.example is included) with:
GOOGLE_STREET_VIEW_API_KEY="your_key_here"
Resolution gotcha: you'll want an upscale pass
Because of the 640px ceiling, your 1080p or 4K dreams need a second step. The README's recipe works and matches the standard advice: pick "16:9 Widescreen (640x360)", feed the image output into an Upscale Image (using model) node with a 4x-UltraSharp upscale model, and you land at 2560x1440. For "more pixels, source already sharp" this is the right tool - the street photo is already crisp, you're just resampling, so a 4x ESRGAN-style model or even Lanczos gives clean results without inventing detail.
Troubleshooting
ValueError: API key not found- your.envis missing, in the wrong folder, or the variable isn't named exactlyGOOGLE_STREET_VIEW_API_KEY.- Black output image - Google has no Street View coverage at that exact coordinate, or the key is invalid/restricted. The API happily returns a 200 with a black body, so check
metadataand your console restrictions. - Node not in the menu - you didn't fully restart ComfyUI after installing.
One honest note: this pack has almost no community footprint yet - zero search impressions, no reddit lore to mine - so the README is your best documentation, and it's actually decent. For a niche node like this, that's fine; the tool works and the failure modes are the same three above.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| location | STRING | 40.720032,-73.988354 | — |
| heading | FLOAT | 151.80–360 | — |
| pitch | FLOAT | -0.8-90–90 | — |
| fov | INT | 9010–120 | — |
| aspect_ratio | COMBO | 5 options: 1:1 Square (640x640), 16:9 Widescreen (640x360), 9:16 Vertical (360x640), 4:3 Classic (640x480), 3:2 Photography (640x427) | |
| historical_date_idopt | STRING | Enter a panorama ID to load a historical image from a specific date |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| metadata | STRING | — |