Login & credits
Loading and applying public styles needs no account. Sign in to use your own private styles — they load by the same share slug or id as any other style.
Sign in on your own computer
- Add the StyleRef Login node. It shows your current status right away.
- Click Sign in (browser).
- Approve in the browser tab that opens — the node’s status flips to
✔ signed in.
No queueing involved. If the sign-in doesn’t complete, the tab says so — it never claims success while the node reports a failure.
No password ever enters ComfyUI. Sign-in uses OAuth with PKCE: StyleRef sends a token back to a temporary local listener. The token is stored at ~/.config/styleref/credentials.json with owner-only permissions.
The styleref CLI uses the same file, so signing in with either signs in both.
Click the status line on the node to re-check the session at any time.
No frontend at all? (API-only install): run npx styleref login on the same machine — the CLI and the nodes share one credentials file, so signing in with either signs in both. Queueing the Login node still reports the current status.
Running ComfyUI on a remote or headless machine
Browser sign-in cannot work here — and this is common. If ComfyUI runs on a rented GPU box, RunPod, a Docker container, or any server you reach over SSH, there is no browser on that machine to open, and its localhost is not your computer’s.
The Login node detects this and prints these instructions instead of hanging.
Recommended: copy your credentials file
Sign in once on a machine that does have a browser, then move the credentials across. The file carries a refresh token, so the remote install renews its own session and keeps working for weeks.
1. On your own computer, sign in with the CLI (or the Login node — they share one file):
npx styleref login2. Copy the file to the same path on the ComfyUI machine:
scp ~/.config/styleref/credentials.json user@gpu-box:~/.config/styleref/credentials.jsonCreate ~/.config/styleref/ first if it doesn’t exist, and keep the copy owner-only:
chmod 600 ~/.config/styleref/credentials.json3. Click the Login node’s status line to re-check — no restart needed.
For Docker, mount the file (-v ~/.config/styleref:/root/.config/styleref) so it survives container restarts and can be rewritten when the token refreshes.
Short-lived alternative: STYLEREF_TOKEN
For a single session or a CI job, set an access token directly:
export STYLEREF_TOKEN="<your access token>"For Docker, pass -e STYLEREF_TOKEN=<token>. For a systemd service, add it to the unit’s Environment=. Restart ComfyUI, then queue the Login node to confirm.
STYLEREF_TOKEN always takes precedence over stored credentials — which is also how you override a login on a shared machine.
Be aware of the tradeoff: an access token expires in about an hour and this path never refreshes it, so a long-running install will start returning 401 errors. Use the credentials file for anything you want to keep working unattended.
If detection gets it wrong
Forwarding a port from a remote box gives you a working loopback even though the machine looks headless. Override it:
export STYLEREF_FORCE_BROWSER_LOGIN=1 # force browser sign-in
export STYLEREF_FORCE_BROWSER_LOGIN=0 # force the token pathCredits
Nothing in the plugin spends credits. Searching, loading, and applying styles — including your own — is free, within the public rate limit.
Extraction (turning an image into a style) is the one action that costs credits — currently 30 on the free plan, unlimited on Pro — and it happens on styleref.io , not in ComfyUI: upload an image there, preview and refine the result block by block, and the style lands in your library. Load it here by its share slug or id — that part is free.
Loading your own style always uses its last generated version. If you’ve edited a style since, open it on styleref.io and hit Generate to refresh what the API serves; a style that has never been generated can’t be loaded yet, and the node’s error says exactly that.
See plans and limits for what extraction costs on the web.
Signing out
Click Sign out on the Login node. This removes the stored credentials file — which also signs out the CLI, since they share it.
If STYLEREF_TOKEN is set, you stay signed in via that token; unset it and restart ComfyUI.