Roman Bedroš
05/19/2026, 10:07 AMMarvin
05/19/2026, 10:07 AMMarvin
05/19/2026, 10:09 AMcrypto.randomUUID is not a function
That happens because UI v2 was calling crypto.randomUUID() directly, and that API is only available in a secure context in browsers — typically:
* https://... works
* <http://localhost>... usually works
* plain http://<server-or-ip> often does not work
So if your self-hosted Prefect UI is being accessed over regular HTTP, that can absolutely explain the failure.
What to do
Best fix: upgrade beyond 3.7.1
This was fixed upstream after 3.7.1 by adding a fallback when crypto.randomUUID() is unavailable. If you can, upgrade to a newer 3.7.x release.
Relevant source:
* Fix in `ui-v2/src/api/csrf.ts`: csrf.ts
* Fix commit: d4554c3022
Alternative fix: serve Prefect over HTTPS
If you need to stay on 3.7.1, put the UI behind HTTPS via your reverse proxy/load balancer (nginx, Traefik, Caddy, etc.). Make sure the browser actually sees an https:// URL.
For example, with a reverse proxy you generally want TLS termination and forwarded headers such as:
X-Forwarded-Proto: https
Quick checks
1. Open the UI using https://... instead of http://...
2. If possible, test from <http://localhost>...
* if localhost works but remote HTTP does not, that strongly confirms this is a secure-context issue
3. Check browser dev tools console again after switching to HTTPS
Bottom line
* Yes, accessing via HTTP can cause this exact UI v2 error.
* The most reliable solution is to upgrade to a version newer than 3.7.1.
* If you stay on 3.7.1, serve the UI over HTTPS.
If you want, I can also help you verify:
* whether your current Prefect version already includes the fix, or
* how to configure HTTPS for your specific setup (Docker Compose, nginx, Traefik, Kubernetes, etc.).Nate
05/19/2026, 4:56 PMNate
05/19/2026, 4:57 PMcrypto.randomUUID is not a function