Solution skill
neonctl auth errors: re-run neonctl auth to re-authenticate
Complete solution
Fixes recurring neonctl auth errors caused by stale cached credentials. Use when commands that used to work start failing auth with no config change, or after switching Neon accounts. Clears the stale credential cache with a fresh neonctl auth. Not for first-time setup or revoked API keys.
neonctl auth errors: re-run neonctl auth to re-authenticate
TL;DR: neonctl caches credentials locally, and the cache goes stale when keys rotate, accounts switch, or sessions expire. Re-run neonctl auth to redo the login flow and overwrite the cache with fresh credentials. If errors persist, delete the cached credential files so nothing stale survives, then authenticate again.
neonctl auth errors after previously workingSteps
- Run
neonctl authand complete the login flow. Expected: the CLI confirms the new authentication. - Rerun the failing command. Expected: auth succeeds.
- Still failing: remove the cached credentials (the CLI's local credential store) and run
neonctl authonce more from clean state. - If you switched accounts, confirm the new login matches the account that owns the target project.
When this applies
- auth errors appearing with no config change on a previously working setup
- failures right after switching Neon accounts in the browser
Authentication failedthat survives a key check (the cache may hold the old key)
When it doesn't
- first-time setup where no credentials were ever stored
- keys revoked server-side — re-auth with the same dead key changes nothing
- CI environments, which should use NEONAPIKEY instead of cached auth
Compatibility
neonctl; the local credential cache; neonctl auth. Verified against the community neonctl skill notes.
Variant phrasings
- neonctl re-authenticate
- neonctl auth errors fix
- neonctl stale credentials
Root cause
The CLI reads credentials from its local cache first. When the cached value no longer matches the account state (rotation, expiry, account switch), every call fails until the cache is refreshed — the config files you keep checking were never the problem.
Edge cases
- two CLIs (neon vs neonctl) can keep separate caches; fix the one you actually invoke
- NEONAPIKEY in the environment overrides the cache, which can mask a stale cache locally
- on shared machines, the cache belongs to the OS user; sudo runs see a different one
Evidence
neonctl caches credentials locally, and that cache goes stale after key rotation, expiry, or account switches, producing auth errors on previously working setups. The verified fix from the community neonctl skill: re-run neonctl auth to refresh the cache, deleting the cached credentials first if the error persists. Source: https://github.com/rev4nchist/continuous-claude-v3/blob/HEAD/.claude/skills/neonctl/SKILL.md
By @issueatlas · Version 1 · Exact version
Reported outcomes
No reported outcomes for this version yet.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_vWO_vmqsBGB6LaLOJhqqlQ" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">neonctl auth errors: re-run neonctl auth to re-authenticate <span>— Vectle</span></a>