📦 ComfyUI Backup & Packager
Your workflow JSON is useless without its models. This node backs up both.
- status_report
ComfyUI's whole sharing culture runs on workflow JSONs - the "workflow included" norm is baked into the ecosystem. But here's the lie hiding in plain sight: that JSON is just text referencing filenames. Drag it onto another machine and it only "works" if every checkpoint, LoRA, and VAE it names happens to exist in the right folder. Lose or purge those models and your beautiful graph is a dead document. 📦 ComfyUI Backup & Packager (class WorkflowBackup) is the node that gathers the JSON and the actual model files it depends on into one self-contained folder. Small, niche, and genuinely handy right before you do something reckless like a disk cleanup or a fresh ComfyUI install.
How it works
The mechanism is refreshingly simple, and since this pack ships no requirements.txt, there's nothing to break. You point it at a folder of workflows, and it does three passes:
- Scan - recursively finds every
*.jsonin that folder. - Resolve - parses each workflow, digs through
widgets_valuesand nodeinputsfor strings ending in.safetensors,.ckpt,.pth,.pt, or.bin, then matches those against yourComfyUI/models/tree to find the real files. It also buckets each model by its subfolder, so checkpoints land undercheckpoints/, LoRAs underloras/, and so on. - Copy - writes the JSONs to
<destination>/workflows_backup/and the models to<destination>/models/<category>/, reusing whatever's already there so re-runs stay cheap.
That's the whole job. No API calls, no keys, no cloud - it's just shutil.copy2 with a progress bar and a really good log.
The inputs that matter
All four are required, but only two are yours to think about:
workflows_path- the folder holding the workflow JSONs you want to bundle. Give it the specific folder (e.g.ComfyUI/user/default/workflows). The author's warning is worth repeating: don't point it at the ComfyUI root, or it'll happily scan system files and fill the log with noise.backup_destination- where the backup lands. The default,output/workflow_backups, works with zero setup.mode-ANALYSIS_ONLYpreviews what would be copied and the total size in GB;EXECUTE_BACKUPactually copies. Run the first one, then the second.language- English or Spanish, matching the bilingual author.
The single output is a status_report string - the whole operation log, printed to the console and shown because the node is an output node. Wire it into a text display if you want it on the canvas.
Installing it
Two ways, both painless:
# via ComfyUI Manager - search "Workflow Backup" and hit Install
# or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/zavatmotion/ComfyUI-Workflow-Backup.git
# restart ComfyUI
There's a bundled Models-Backup.json example workflow you can load to see it wired up.
The gotcha that will actually trip you up
The node blocks writes outside your ComfyUI folder by design - a path sanitizer plus a whitelist, in the spirit of the ecosystem's security scars. To back up to a USB drive, NAS, or secondary disk, you must create extra_paths.json in the node directory (there's an extra_paths.example.json in the repo) listing every allowed root:
{
"allowed_paths": [
"D:/ComfyUI_Backup",
"E:/MyExternalDrive",
"/mnt/backups"
]
}
Miss this and any external path gets rejected with a ⛔ SECURITY ERROR and the backup silently lands in output/workflow_backups instead. It's the one step the README spends a whole section on, because it's the one everyone hits.
Honest limitations
Model detection is string-based, so a workflow that references a model by a bare filename will resolve fine, but anything unusual (a path that doesn't exist, a weird extension) gets skipped quietly. It won't track which checkpoint was actually used - only which filenames appear. For the common case - "make me a portable copy of this project" - it's exactly right. Just run ANALYSIS_ONLY first and eyeball the count before you commit to copying 20GB.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| workflows_path | STRING | Paste your path here | — |
| backup_destination | STRING | output/workflow_backups | — |
| mode | COMBO | 2 options: ANALYSIS_ONLY, EXECUTE_BACKUP | |
| language | COMBO | 2 options: English, Spanish |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| status_report | STRING | — |