JSON Dynamic Loader
Turn a JSON file into your whole workflow's settings panel
- output_0
- output_1
- output_2
- output_3
- output_4
- output_5
- output_6
- output_7
- output_8
- output_9
- output_10
- output_11
- output_12
- output_13
- output_14
- output_15
- output_16
- output_17
- output_18
- output_19
- output_20
- output_21
- output_22
- output_23
- output_24
- output_25
- output_26
- output_27
- output_28
- output_29
- output_30
- output_31
Every workflow ends up with the same mess: prompts, seeds, and settings buried inside widget boxes across twenty nodes, so "one authoritative source" is a fiction you maintain by hand. The JSON Dynamic Loader is the fix - point it at a JSON file and it turns every key into a named output with the right connector color, so your values live in one editable, diffable, scriptable file instead of scattered widgets. It's the pack's flagship, and it's the reason to install ComfyUI-JSON-Dynamic in the first place.
How it works
The node reads a JSON file on disk (json_path), and for each key it detects the type and exposes it as a slot: integers come out as INT (blue connector), floats as FLOAT (teal), and strings and booleans as STRING (pink). Booleans arrive as the lowercase strings "true" / "false", so don't expect a BOOLEAN socket.
The bit that feels like magic is the Refresh Outputs button. Click it and the node calls ComfyUI's backend API, re-reads the file, and rebuilds its outputs - but it reuses existing output slots by name, so anything already wired stays connected and only genuinely removed keys get their links dropped. Adding a key to your JSON and hitting Refresh just grows a new output. Your connections survive save/reload too, because the resolved key names and types are stashed in hidden output_keys / output_types widgets.
That's also why info_schema shows 32 identical output_0…output_31 slots - that's the hard ceiling the Python side declares. On the canvas you'll only see the slots for your actual keys once you've refreshed.
The two inputs that matter
json_path- a filesystem path to your JSON. Absolute paths are the safest bet.sequence_number(default 1) - selects a segment when your file uses thebatch_datashape.
The output_keys and output_types widgets exist in the schema but are hidden and managed by the JS; you never touch them.
Batch mode
For multi-shot work, wrap your segments in a batch_data array where each entry carries its own sequence_number, prompt, seed, whatever. The node matches the sequence_number input to an entry's sequence_number field, falls back to sequence_number - 1 as an array index, and reads root keys directly if there's no batch_data at all. Segments can be out of order and gapped (1, 5, 10). The one trap: each segment can have different keys, and the outputs only update when you hit Refresh - so if you change sequence_number to a segment with new keys, re-refresh or you'll get empty values.
Install
ComfyUI Manager, search JSON Dynamic Loader, or:
cd ComfyUI/custom_nodes
git clone https://github.com/ethanfel/ComfyUI-JSON-Dynamic.git
# restart ComfyUI
No extra Python packages, no model downloads - this one only needs what ComfyUI already ships.
Common issues
- Nothing happens after I edit the JSON. You have to click Refresh Outputs; the node doesn't watch the file. That's by design (a file watcher would re-trigger constantly).
- I deleted a key and the old output is still there. If the file is missing entirely, the node deliberately keeps your existing outputs and links so a typo in the path doesn't shred your graph. Fix the path, refresh.
- My boolean came out as a string. Yes - per the type table,
true/falsebecome"true"/"false". If a downstream node needs a real BOOLEAN, convert it.
It's plumbing, not glamour, but it's the kind of plumbing that turns a one-off workflow into a config-driven pipeline you can hand to a script.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| json_path | STRING | — | |
| sequence_number | INT | 11–9999 | — |
| output_keysopt | STRING | — | |
| output_typesopt | STRING | — |
Outputs (32)
| Name | Type | Description |
|---|---|---|
| output_0 | * | — |
| output_1 | * | — |
| output_2 | * | — |
| output_3 | * | — |
| output_4 | * | — |
| output_5 | * | — |
| output_6 | * | — |
| output_7 | * | — |
| output_8 | * | — |
| output_9 | * | — |
| output_10 | * | — |
| output_11 | * | — |
| output_12 | * | — |
| output_13 | * | — |
| output_14 | * | — |
| output_15 | * | — |
| output_16 | * | — |
| output_17 | * | — |
| output_18 | * | — |
| output_19 | * | — |
| output_20 | * | — |
| output_21 | * | — |
| output_22 | * | — |
| output_23 | * | — |
| output_24 | * | — |
| output_25 | * | — |
| output_26 | * | — |
| output_27 | * | — |
| output_28 | * | — |
| output_29 | * | — |
| output_30 | * | — |
| output_31 | * | — |