ComfyUI saves workflows as .json files in its user directory. The exact location depends on the install: the docs say it differs between the desktop app's user data, a portable or self-hosted user directory, and cloud workspace storage.
What the source says
- On a manual or portable install, the user directory is the
userfolder inside the ComfyUI folder by default, and the default user is nameddefault(folder_paths.py,user_manager.py). --user-directorysets it to an absolute path of your choice.--base-directorymoves the models, custom nodes, input, output, temp and user directories together.- Saved workflows are listed in the interface under Browse, as a folder tree of the workflow storage path for the install. Renaming a workflow renames the file on disk.
Other ways to keep a workflow
Ctrl+Ssaves the current workflow andCtrl+Oloads one.- A generated PNG carries its whole workflow, including seeds: load the image to restore it.
- For use from scripts, the File menu has an Export (API) option, which writes the API-format JSON: see how to use the ComfyUI API.
Images and other outputs go to a different folder: where ComfyUI saves images. Workflows that use extra nodes will show red boxes until you install them: the ComfyUI custom node install guide and the ComfyUI Manager guide cover that.
Sources
- ComfyUI docs: Workflows. docs.comfy.org
- ComfyUI folder_paths.py. github.com
- ComfyUI cli_args.py (--user-directory, --base-directory). github.com
- ComfyUI README: Features and Shortcuts. github.com
- ComfyUI basic_api_example.py (Export (API)). github.com