Nodes/ComfyUI Input Thumbnails/Load Image (Gallery)
ComfyUI Node

Load Image (Gallery)

Load Image, but you can finally see the pictures

By panjapongr·Created 27 days ago·Updated 23 days ago· 1
Load Image (Gallery)
    • image
    • mask
    ◄image▾►

    The built-in Load Image node hands you a dropdown of filenames. With eleven files in ComfyUI/input, that's fine. With a year of ControlNet poses, character refs and mask plates piled up in there, you're scrolling a text list trying to remember whether the pose you want is pose_0042.png or pose_0043.png. People keep asking for exactly this in one form or another: it should be a visual browser inside ComfyUI.

    Load Image (Gallery) is that browser: a grid of thumbnails with subfolders, search, sort and pagination. It's not a replacement for core Load Image, and it doesn't touch your files.

    How it works

    Python node plus a small frontend extension. The Python side registers the LoadImageGallery class along with three routes (/input_thumbs/list, /input_thumbs/thumb, /input_thumbs/settings); the JavaScript adds a Browse thumbnails button to the node and draws the grid in a modal. Click a folder card to descend, ↑ to go up, click a thumbnail to select it, and the selection is written back into the node's image value.

    Thumbnails cache to ComfyUI/input/.cache/thumb/, sharded by SHA-256 prefix, saved as WebP up to 320px. On a miss the route serves your original file immediately so the grid never stalls, and builds the thumbnail in a background thread. The cache keys on filename and content hash, so overwriting an image in place refreshes its thumbnail and deletes the stale one.

    Whatever you pick, execution always loads the full-resolution original. Compressed cache, uncompressed load.

    Two behaviors worth knowing:

    • Alpha becomes the mask, inverted (1.0 - alpha), same convention as the core loader. No alpha channel, and you get a zeros mask.
    • Animated files come out as a frame batch. It walks frames with Pillow's ImageSequence, so a GIF or animated WebP yields a stacked IMAGE batch, not one frame. Handy if you meant it, surprising if you didn't.

    It also overrides IS_CHANGED with a fingerprint of path, file size and mtime_ns, so replacing a file that has the same name properly invalidates your cached run instead of reusing the old result.

    Inputs and outputs

    There's one input. image is a combo of every image file found recursively under input/, subfolder paths included, sorted case-insensitively. Uploading stays enabled on it, so the normal choose file to upload button still works - upload a new reference and it lands in input/ and shows up in the list. On an empty input/ you get a placeholder entry and a plain "Select an image from the gallery" error instead of a cryptic crash.

    Outputs are image (IMAGE) and mask (MASK). Same pair as core Load Image, wire them into the same places.

    Keep this in mind: only input/ is browsable, not output/ or temp/. That folder is also why shared workflows break on someone else's machine: "can't find my image" almost always means the file isn't in input/.

    Install

    Via ComfyUI Manager, search Input Thumbnails (registry display name "ComfyUI Input Thumbnails", publisher panjapong). Or by hand:

    cd ComfyUI/custom_nodes
    git clone https://github.com/panjapongr/ComfyUI-InputThumbnails
    

    Then restart ComfyUI and hard-refresh the browser (Ctrl+F5, Cmd+Shift+R). That second step isn't optional: the grid is a frontend extension, and a stale cached frontend is the most likely reason you get a node with no button on it.

    No model downloads, and no pip dependencies. The pack ships no requirements.txt, and everything it imports (Pillow, numpy, torch, aiohttp) already comes with ComfyUI. That matters more than it sounds - most packs this size drag in a dependency that collides with something else you've installed.

    Common issues

    Node missing from the menu. Usually a nested folder after unzipping. You want ComfyUI/custom_nodes/ComfyUI-InputThumbnails/__init__.py to exist, not a second ComfyUI-InputThumbnails directory inside the first.

    Node there, no Browse thumbnails button. Frontend cache, or an old ComfyUI frontend. Hard-refresh, then check the browser console for a failed input_thumbnails.js load.

    Files you just dropped into input/ aren't in the dropdown. The grid has its own ↻ Refresh button, and picking from it feeds the new path straight into the widget, but the combo list is built when the node is created. Re-add the node or reload the tab if the dropdown itself needs to know.

    You end up with two loaders, and thumbnails eat a little disk. This pack uses its own class name, so it won't fight packs that override core LoadImage; you just get both nodes side by side (the author's note: don't install this and an override pack if you only wanted one picker). The cached thumbnails in input/.cache/thumb/ are hidden from the picker and safe to delete any time - the folder rebuilds on demand.

    Worth it?

    The honest framing: this is a brand-new single-author pack with effectively zero search traffic, at version 1.3.0, GPL-3.0. Not famous, and I won't pretend otherwise. But it's small - one ~700-line Python file and one JS file, no dependencies, no telemetry, every path clamped inside input/ with .. and absolute paths rejected. Easy to read yourself, which is the lowest-stakes version of the "every custom node is code running in your environment" decision you'll ever make.

    If you keep a real reference library in input/, install it and stop guessing at filenames.

    Categoryimage

    Inputs (1)

    NameTypeDefaultDescription
    imageCOMBO1 options: example.png

    Outputs (2)

    NameTypeDescription
    imageIMAGE—
    maskMASK—