VAE Decode Switch
Swapping VAEDecode and VAEDecodeTiled without rewiring
- samples
- vae
- IMAGE
Every ComfyUI graph ends the same way: a latent tensor walks into a VAE decoder and walks out as pixels. The catch is there are two decoders - the plain VAE Decode and the VAE Decode (Tiled) - and picking the wrong one for the job is the kind of thing you discover at the worst possible time, when a 1080p still or a long Wan clip runs out of VRAM mid-decode. VAE Decode Switch (VAEDecodeSwitcher, by MasterDenis) is a tiny utility that puts both behind one dropdown so you can flip between them without touching a single wire.
Is it life-changing? No. It's one node from a one-node pack, and if your workflow never needs tiled decode, you don't need it. But if you're A/B testing decode methods or building a shared template that other people run on different GPUs, it saves you from keeping two parallel decoders glued onto the same latent just to compare them. That's the whole pitch: one socket, two decoders, zero rerouting.
How it works
Under the hood it's honest about being a wrapper. The node imports VAEDecode and VAEDecodeTiled straight from ComfyUI's own nodes module and calls whichever one your dropdown points at. No new decoding logic, no model files, no extra dependencies - it's the same decoders you already have, just behind a switch.
The one genuinely clever bit lives in the frontend. The pack ships a small JS extension that hides the tiled-only settings (tile_size, overlap, and the two temporal ones) whenever you select default, so the node shrinks down to just its three main inputs. Select tiled and the settings reappear. It's a nicer UX than most nodes this size bother with.
The inputs that matter
You wire it exactly like you'd wire a normal decoder:
- samples (LATENT) and vae (VAE) - same inputs every decode takes.
- select_decoder - the dropdown:
default(standardVAEDecode) ortiled(VAEDecodeTiled). - tile_size (default 512) and overlap (default 64) - how big each decode tile is and how much the tiles bleed into each other. Bigger tiles use more VRAM but give cleaner seams; overlap too small shows tile boundaries.
- temporal_size (64) and temporal_overlap (8) - only relevant for video latents (Wan and friends), where decoding happens along the time axis too. For a still image they're ignored, so don't stress about them.
The single output is an IMAGE, which feeds straight into a preview or a save node. This is not an output node - it won't render anything on its own.
Installing it
ComfyUI Manager has it: search for VAE Decode Switch (or "MasterDenis"). Prefer git, the repo is four small files:
cd ComfyUI/custom_nodes
git clone https://github.com/MasterDenis/VAE-Decode-Switch
Then restart ComfyUI completely. There's nothing to download - no models, no pip deps beyond the torch and core nodes you already have. The folder name matters (the python module is custom_nodes.VAE-Decode-Switch), so let the clone keep its name.
Where people get burned
The biggest trap is a real one and it's in the source: if the tiled path throws a TypeError, the node doesn't error out - it returns a tiny black 64×64 image. That's a deliberate fallback, but it means a silently-wrong output instead of a red error when something's off. If you ever get a black frame from a tiled decode, that's what happened; check your ComfyUI version's VAEDecodeTiled.decode signature, because the temporal arguments change between versions.
The other two gotchas are the tiled decoder's usual ones. First, memory: tiled decode is mostly for dodging OOM on big images and video, so cranking tile_size up defeats the purpose - if you're still running out of VRAM, drop the tile size and raise the overlap. Second, quality: tiled decode is a workaround, not an upgrade. People have reported occasional glitches around fixed points in video clips from the tiled path, so if you're using it for output quality rather than necessity, sanity-check the result against plain decode first. For most stills, plain VAE Decode is fine these days - ComfyUI's memory handling got better and most people only reach for tiled when they have to. This node just makes having to much less annoying.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| samples | LATENT | — | |
| vae | VAE | — | |
| select_decoder | COMBO | 2 options: default, tiled | |
| tile_sizeopt | INT | 51264–4096 | — |
| overlapopt | INT | 640–4096 | — |
| temporal_sizeopt | INT | 641–4096 | — |
| temporal_overlapopt | INT | 80–4096 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |