Errors

Could not load CSRF token

Admin page helper got /api/auth/csrf without a token field (or failed load).

Could not load CSRF token

Admin UI helpers (user edit, files, trash, anti-hack, shared admin-fetch-helpers) refuse to continue when /api/auth/csrf returns no token. Exact string: Could not load CSRF token.

Why this happens

Nearly the same root cause as Could not get CSRF token (admin CSRF helpers). This wording is the throw when the JSON body lacks token after a successful-looking fetch pattern in those pages.

Diagnose and fix

1. Re-auth as staff; hard refresh; retry the action.

2. Inspect GET /api/auth/csrf in DevTools.

3. Fix cookie / HTTPS / reverse-proxy path issues for /api/*.

4. Member-facing auth forms usually show Could not load security token — refresh the page instead.

Related