Load Layers PSD
Your Photoshop files, layer by layer, no Photoshop needed
- composite_image
- layers_batch
- masks_batch
- layer_1_image
- layer_1_mask
- layer_2_image
- layer_2_mask
- layer_3_image
- layer_3_mask
- layer_4_image
- layer_4_mask
- layer_5_image
- layer_5_mask
- layer_6_image
- layer_6_mask
- layer_7_image
- layer_7_mask
- layer_8_image
- layer_8_mask
- layer_9_image
- layer_9_mask
- layer_10_image
- layer_10_mask
- layer_11_image
- layer_11_mask
- layer_12_image
- layer_12_mask
- layer_13_image
- layer_13_mask
- layer_14_image
- layer_14_mask
- layer_15_image
- layer_15_mask
- layer_16_image
- layer_16_mask
- layer_17_image
- layer_17_mask
- layer_18_image
- layer_18_mask
- layer_19_image
- layer_19_mask
- layer_20_image
- layer_20_mask
- layer_21_image
- layer_21_mask
- layer_22_image
- layer_22_mask
- layer_23_image
- layer_23_mask
- layer_24_image
- layer_24_mask
- layer_25_image
- layer_25_mask
- layer_26_image
- layer_26_mask
- layer_27_image
- layer_27_mask
- layer_28_image
- layer_28_mask
- layer_29_image
- layer_29_mask
- layer_30_image
- layer_30_mask
- layer_31_image
- layer_31_mask
- layer_32_image
- layer_32_mask
ComfyUI has always been bad with layered files. LoadImage gives you one flattened raster, and anything you save flattens again. So when your source of truth is a PSD - a designer's comp, a client's edit, a file somebody worked on in Photoshop - you used to flatten it by hand before the graph could touch it. Load Layers PSD fixes that. It reads a real PSD or PSB layer by layer, hands you a composite plus per-layer image/mask pairs, and does it with zero Photoshop installed.
This is the generic load half of the ComfyUI-PSD-Layers pack (the save half is Save Seedream Layers PSD, built for Seedream's layer separation). If your work touches layered Photoshop files at all - say, for compositing, per-layer inpainting, or recoloring - this is the node you've been missing.
What comes out
The node is almost absurdly generous: three batch outputs, then 32 per-layer image/mask pairs (layer_1_image, layer_1_mask, layer_2_image… up to layer_32_mask). What you'll actually wire:
- composite_image - the full merged render. Straight into a SaveImage or VAE decode for preview.
- layers_batch / masks_batch - every layer on a full-canvas batch, with no 32-layer ceiling. Feed these to anything that wants a batch of images.
- layer_N_image / layer_N_mask - tight crops of each layer, in bottom-to-top PSD order. Unused slots collapse away in the UI, so you're not staring at 32 empty sockets.
How it works
Under the hood it's psd-tools. Only leaf layers are extracted - groups get flattened, and layer masks, group raster masks, and clipping masks are pre-applied into each layer's alpha. Text layers use the embedded raster, so no fonts are needed, and shape layers are rasterized from their vector masks. Every Photoshop blend mode is supported through psd-tools' blend engine, with the README measuring about 0.03/255 error against Photoshop's own render. Before you touch anything, the composite is the PSD's embedded Photoshop render - pixel-perfect.
Two inputs you actually set. psd is a dropdown of files in your input folder, and you can drag & drop a file straight onto the node instead. psd_path is an absolute server-side path for the edit-in-Photoshop-then-reload loop: set it, edit the file, hit Reload (or just re-run - the node reloads automatically when the file's mtime changes). The layer_state widget is managed by the panel for you; you never type into it.
Gotchas
- Adjustment layers and layer styles aren't applied when the node recomposites after you reorder or hide things. The untouched composite uses Photoshop's embedded render, but once you edit, expect a status-bar warning and a result that differs slightly from what Photoshop would show.
- Masks come out as 1 = transparent, inverted from the usual LoadImage convention. Keep that in mind before wiring into nodes that assume 1 = opaque.
- Per-layer outputs keep their original PSD order even after you drag layers around in the panel; only the composite reflects your edits.
Install
ComfyUI Manager (search "PSD Layers" or "ComfyUI-PSD-Layers"), or the manual route:
cd ComfyUI/custom_nodes
git clone https://github.com/coeyes/ComfyUI-PSD-Layers
cd ComfyUI-PSD-Layers
pip install -r requirements.txt # psd-tools>=1.18.0, pillow, numpy
Then restart ComfyUI. No model files, no API keys - this is pure file parsing. psd-tools 1.18+ is a hard requirement and the code refuses to start without it; if it errors, pip install -U "psd-tools>=1.18.0" first.
Troubleshooting
- "PSD file not found" - the dropdown lists files in your
inputfolder; on a remote server the path must be readable server-side. - psd_path rejected - it has to be a
.psd/.psbfile that actually exists on the server machine, not your local PC. - More than 32 layers - the batch outputs carry everything; the per-layer slots just stop at 32, and the node logs a warning about it.
That's the whole pitch: load, look, wire, re-save. It quietly turns ComfyUI from "Photoshop's flat export" into something that can work with the layered file itself.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| psd | COMBO | PSD file in the input folder. You can also drag & drop a file onto the node. | |
| layer_state | STRING | Layer order/visibility state edited in the panel (managed automatically). | |
| psd_pathopt | STRING | Absolute path on the server (.psd/.psb). When set, this file is read instead of the psd combo above. Useful for the edit-in-Photoshop-then-Reload workflow. For remote access the path must be readable by the server. |
Outputs (67)
| Name | Type | Description |
|---|---|---|
| composite_image | IMAGE | — |
| layers_batch | IMAGE | — |
| masks_batch | MASK | — |
| layer_1_image | IMAGE | — |
| layer_1_mask | MASK | — |
| layer_2_image | IMAGE | — |
| layer_2_mask | MASK | — |
| layer_3_image | IMAGE | — |
| layer_3_mask | MASK | — |
| layer_4_image | IMAGE | — |
| layer_4_mask | MASK | — |
| layer_5_image | IMAGE | — |
| layer_5_mask | MASK | — |
| layer_6_image | IMAGE | — |
| layer_6_mask | MASK | — |
| layer_7_image | IMAGE | — |
| layer_7_mask | MASK | — |
| layer_8_image | IMAGE | — |
| layer_8_mask | MASK | — |
| layer_9_image | IMAGE | — |
| layer_9_mask | MASK | — |
| layer_10_image | IMAGE | — |
| layer_10_mask | MASK | — |
| layer_11_image | IMAGE | — |
| layer_11_mask | MASK | — |
| layer_12_image | IMAGE | — |
| layer_12_mask | MASK | — |
| layer_13_image | IMAGE | — |
| layer_13_mask | MASK | — |
| layer_14_image | IMAGE | — |
| layer_14_mask | MASK | — |
| layer_15_image | IMAGE | — |
| layer_15_mask | MASK | — |
| layer_16_image | IMAGE | — |
| layer_16_mask | MASK | — |
| layer_17_image | IMAGE | — |
| layer_17_mask | MASK | — |
| layer_18_image | IMAGE | — |
| layer_18_mask | MASK | — |
| layer_19_image | IMAGE | — |
| layer_19_mask | MASK | — |
| layer_20_image | IMAGE | — |
| layer_20_mask | MASK | — |
| layer_21_image | IMAGE | — |
| layer_21_mask | MASK | — |
| layer_22_image | IMAGE | — |
| layer_22_mask | MASK | — |
| layer_23_image | IMAGE | — |
| layer_23_mask | MASK | — |
| layer_24_image | IMAGE | — |
| layer_24_mask | MASK | — |
| layer_25_image | IMAGE | — |
| layer_25_mask | MASK | — |
| layer_26_image | IMAGE | — |
| layer_26_mask | MASK | — |
| layer_27_image | IMAGE | — |
| layer_27_mask | MASK | — |
| layer_28_image | IMAGE | — |
| layer_28_mask | MASK | — |
| layer_29_image | IMAGE | — |
| layer_29_mask | MASK | — |
| layer_30_image | IMAGE | — |
| layer_30_mask | MASK | — |
| layer_31_image | IMAGE | — |
| layer_31_mask | MASK | — |
| layer_32_image | IMAGE | — |
| layer_32_mask | MASK | — |