c909f854f45a0c5a17443761d8e75c306eaeb0fa
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
A single ComfyUI node that reads any JSON file and automatically creates output slots for every key it finds. No hardcoded outputs — when your JSON structure changes, just click Refresh.
Features
- Auto-discovery — reads JSON keys and exposes them as named outputs
- Type detection —
INT,FLOAT,STRINGtypes with colored connectors - Batch support —
sequence_numberinput forbatch_dataarrays - Connection-safe refresh — adding new keys preserves existing links
- Workflow persistence — keys, types, and connections survive save/reload
Installation
cd ComfyUI/custom_nodes/
git clone <this-repo> ComfyUI-JSON-Dynamic
# Restart ComfyUI
Usage
- Add JSON Loader (Dynamic) node to your workflow
- Enter a
json_pathandsequence_number - Click Refresh Outputs
- Outputs appear named after your JSON keys with correct types
- Connect to downstream nodes
Type Handling
| JSON type | Output type | Connector |
|---|---|---|
42 (integer) |
INT |
Blue |
3.14 (float) |
FLOAT |
Teal |
"hello" (string) |
STRING |
Pink |
true / false |
STRING ("true" / "false") |
Pink |
JSON Format
Works with flat JSON or batch_data arrays:
{
"batch_data": [
{
"sequence_number": 1,
"general_prompt": "A cinematic scene...",
"seed": 42,
"flf": 0.5,
"camera": "pan_left",
"my_custom_key": "any value"
}
]
}
Without batch_data, reads keys directly from the root object.
License
Description
Languages
Python
64.1%
JavaScript
35.9%