Cullen Baker
11/25/2025, 7:41 PMMarvin
11/25/2025, 7:41 PMMarvin
11/25/2025, 7:46 PMprefect logs <flow-run-id> --follow
- Reduce log volume in flows when possible (avoid log_prints=True unless needed, lower log level).
If you self-host Prefect Server (3.x)
- Disable live event streaming to browsers (biggest impact):
export PREFECT_SERVER_EVENTS_STREAM_OUT_ENABLED=false
- Cut WebSocket backfill size/time so the browser receives less on connect:
export PREFECT_SERVER_EVENTS_WEBSOCKET_BACKFILL_PAGE_SIZE=100
export PREFECT_SERVER_EVENTS_MAXIMUM_WEBSOCKET_BACKFILL=PT5M
- Slow down server background loops (less CPU churn):
export PREFECT_SERVER_SERVICES_SCHEDULER_LOOP_SECONDS=120
export PREFECT_SERVER_SERVICES_FOREMAN_LOOP_SECONDS=30
export PREFECT_SERVER_SERVICES_LATE_RUNS_LOOP_SECONDS=10
- Optional (UI-only environments): disable non-essential services
export PREFECT_SERVER_SERVICES_SCHEDULER_ENABLED=false
export PREFECT_SERVER_SERVICES_LATE_RUNS_ENABLED=false
export PREFECT_SERVER_SERVICES_EVENT_PERSISTER_ENABLED=false
- Then restart your Prefect Server process so settings take effect.
General
- Upgrade to the latest Prefect 3.x for ongoing UI performance improvements.
- Keep one team page open at a time during heavy periods.
A couple questions so I can tailor this:
- Are you using Prefect Cloud UI or a self-hosted Prefect Server UI?
- Which pages spike usage (Dashboard, Runs list, a specific flow run with heavy logs/graph)?
- Roughly how many runs/log lines are visible when you notice the slowdown?
- Which browser/OS? (I can suggest browser-specific tweaks if helpful.)
If you’re self-hosting on RHEL9 and want, I can share a ready-to-drop systemd unit/env file that applies the low-resource settings above.