# ComfyUI Image Browser
A full-screen media gallery for ComfyUI. Browse any folder of generated images/videos, preview them large on hover, and double-click to load the exact workflow that produced them — straight back onto your canvas.
No separate app, no drag-and-drop required — it's a ComfyUI extension that opens as an overlay on top of your existing canvas.
- Folder browsing — jump to Output/Input/Temp with one click, click into subfolders, or type any absolute path. "↑ Up" navigation and clickable subfolder chips included.
- Double-click to load a workflow — reads the workflow graph ComfyUI
embeds in every saved PNG/WebP (and, best-effort, in video metadata via
ffprobe) and loads it with the same API stock drag-and-drop uses. - Large hover preview — hover any thumbnail/video for a big (~900px), real-quality floating preview that follows your cursor and stays clear of the screen edges. Videos play muted/looped; images use a server-side resized preview so it's fast without shipping full-size originals.
- Search, sort, and filter — search by filename, sort by newest/oldest/name, filter to just images or just videos, and adjust thumbnail size with a slider.
- Favorites — star any folder to pin it for one-click access from the folder dropdown.
- Compare mode — select any number of images/videos and view them side-by-side in a scrollable row.
- Live updates — the gallery listens for ComfyUI's own "finished generating" event and refreshes automatically, with a polling fallback; toggle it off if you'd rather refresh manually.
- Day/night theme toggle, independent of your ComfyUI theme.
- Draggable floating launcher — a badge that sits on your canvas so you can open the gallery without going through the sidebar. Drag it anywhere; position is remembered.
Option A — git clone (recommended, makes updates a git pull):
cd ComfyUI/custom_nodes
git clone https://github.com/ComfyUI-ImageBrowser.gitOption B — manual copy:
Copy this whole folder into ComfyUI/custom_nodes/ so you end up with:
ComfyUI/custom_nodes/ComfyUI-ImageBrowser/
__init__.py
server.py
web/
index.js
style.css
Then:
- Restart ComfyUI.
- Look for the "Image Browser" icon in the left sidebar rail, or the round draggable launcher badge on the canvas. Either opens the gallery.
- Required: ComfyUI with a frontend that supports
app.extensionManager.registerSidebarTab(present since the sidebar-tab UI shipped in 2024). Pillow, already a ComfyUI dependency, handles all image thumbnailing/preview generation. - Optional, for nicer video support:
opencv-python(falls back toffmpegon PATH, then to a generic icon) for generating video thumbnail frames.ffprobeon PATH for reading embedded workflow metadata out of video files (e.g. ones saved by "VHS Video Combine"). Images don't need this — that path only relies on Pillow.
Nothing here is a hard requirement; missing optional tools just mean graceful fallbacks (generic icon instead of a real video thumbnail, no workflow-load option for that specific video).
ComfyUI embeds the full workflow graph as JSON in the metadata of every
image it saves — that's what lets you drag a PNG onto the canvas and get
the workflow back. This extension's backend reads that same metadata and
hands the JSON to the frontend, which calls app.loadGraphData() — the
same call stock drag-and-drop uses — so it behaves identically, just
triggered by a double-click in the gallery instead.
- The folder path box accepts any absolute path on the machine ComfyUI is
running on — same trust model as ComfyUI itself (local software you run,
not a hosted multi-user service). To restrict browsing to specific
roots, edit
_safe_listdirinserver.py. - Thumbnails/previews are cached in
_thumb_cache/inside this folder, keyed by file path + modified time. Safe to delete anytime; it'll regenerate as needed. - Favorites, theme, sort/filter, and launcher-badge position are all stored in your browser's local storage (per-browser, not synced).
MIT (or whatever you'd like — update this before publishing). "# ImageBrowser"