Summary
When pressing F5 (browser refresh) in the WebChat UI, the entire visible conversation and queue state is lost. The chat area resets to empty, and there is no indication of:
- What messages were pending/queued
- What the agent is currently working on
- What tool calls are in progress
- How far along a multi-step operation is
For power users who rely on WebChat as their primary interface, this makes it very difficult to maintain situational awareness of what the agent is doing — especially during long-running operations.
Steps to Reproduce
- Open WebChat, start a conversation
- Send a message that triggers a multi-step operation (e.g., spawning sub-agents, running multiple tool calls)
- Press F5 (or browser refresh)
- Result: Chat is empty. No history loaded. No queue state visible. No way to know what the agent is doing.
- Must wait for the agent to finish and respond, with no visibility into progress.
Expected Behavior
After refresh, the UI should:
- Reconnect to the gateway WebSocket
- Restore recent conversation history (at minimum the current session's messages)
- Show current queue state (pending messages, active tool calls)
- Resume showing streaming output if the agent is mid-response
Current Behavior
- Chat area is completely blank after refresh
- No conversation history is loaded
- No queue or processing state is shown
- The agent continues working server-side, but the user has zero visibility
- When the agent finishes, the response appears — but without the original question/context
Impact
This is particularly painful for:
- Power users who use WebChat as their primary daily interface
- Multi-step operations (sub-agent spawns, file operations, research tasks) where you need to track progress
- Accidental refreshes (F5 muscle memory, browser auto-refresh, network hiccup)
- Mobile browsers that may reload tabs from memory
Enhancement Proposal: Queue Visibility & Session Persistence
Drawing inspiration from how other AI interfaces handle this:
A. Session History Persistence (like Claude.ai, ChatGPT)
| Feature |
Claude.ai |
ChatGPT |
OpenClaw WebChat (current) |
| History survives refresh |
✅ Full history |
✅ Full history |
❌ Lost |
| Session list sidebar |
✅ |
✅ |
Partial (dropdown) |
| Resume mid-stream |
✅ |
✅ |
❌ |
| Search past conversations |
✅ |
✅ |
❌ |
Proposal: On WebSocket reconnect, fetch the current session's message history from the gateway (the data exists server-side in sessions store) and render it. This should be the default behavior — users should never see a blank chat after refresh.
B. Queue & Processing State Panel
A persistent, lightweight status area (could be a collapsible panel, sidebar section, or header bar) showing:
┌─────────────────────────────────────────┐
│ 🔧 Agent Status: Working │
│ │
│ Queue depth: 2 │
│ ├─ 🔄 [active] Executing: exec (pid │
│ │ 12345) — running 15s │
│ ├─ ⏳ [queued] web_search: "openclaw │
│ │ upgrade guide" │
│ │
│ Sub-agents: 1 running │
│ └─ 🔄 research-task (45s, 30% context) │
│ │
│ Session: agent:main:main │
│ Context: 44% (89k/200k) │
│ Model: claude-opus-4-5 │
└─────────────────────────────────────────┘
This gives the user:
- Is the agent doing something? (not just a blank screen or spinner)
- What specifically? (tool name, command, search query)
- How long has it been running? (elapsed time per operation)
- What's queued next? (pending operations)
- Sub-agent status (spawned tasks and their progress)
- Resource awareness (context %, model in use)
C. Activity Feed / Event Log
A scrollable event log (like a terminal or CI/CD pipeline view) that shows real-time events:
14:31:02 Message received from user
14:31:03 Agent thinking...
14:31:05 Tool call: exec (powershell -Command "openclaw --version")
14:31:06 Tool result: 2026.1.30 (exit 0)
14:31:06 Tool call: session_status
14:31:07 Tool result: OK (context 44%)
14:31:08 Agent composing response...
14:31:10 Response delivered (245 tokens)
This is different from the chat view — it's a machine-readable audit trail that power users can glance at to understand exactly what happened, especially after a refresh.
D. Reconnection Resilience
When the WebSocket reconnects (after refresh, network drop, or tab wake):
- Immediately: Show "Reconnecting..." with last known state
- On connect: Fetch session history + current queue state
- If agent is mid-response: Resume streaming from current position
- If agent finished while disconnected: Show the completed response with a "delivered while you were away" indicator
E. Keyboard Shortcut Guard
Optionally intercept F5/Ctrl+R with a confirmation dialog when the agent is actively processing:
"The agent is currently working on your request.
Refreshing will hide the progress view. Continue?"
[Refresh] [Cancel]
This is a common pattern in web apps with unsaved state (Google Docs, Figma, etc.).
Implementation Notes
- Session message history already exists server-side — the WebSocket
sessions.history method can fetch it on reconnect
- Queue depth is available via the
collect queue state (already shown in session_status)
- Tool call events are already emitted over WebSocket — just need UI rendering
- The Activity Feed could reuse existing gateway log events
Environment
- OpenClaw 2026.1.30
- Windows 10, Chrome/Edge
- WebChat as primary interface
Summary
When pressing F5 (browser refresh) in the WebChat UI, the entire visible conversation and queue state is lost. The chat area resets to empty, and there is no indication of:
For power users who rely on WebChat as their primary interface, this makes it very difficult to maintain situational awareness of what the agent is doing — especially during long-running operations.
Steps to Reproduce
Expected Behavior
After refresh, the UI should:
Current Behavior
Impact
This is particularly painful for:
Enhancement Proposal: Queue Visibility & Session Persistence
Drawing inspiration from how other AI interfaces handle this:
A. Session History Persistence (like Claude.ai, ChatGPT)
Proposal: On WebSocket reconnect, fetch the current session's message history from the gateway (the data exists server-side in sessions store) and render it. This should be the default behavior — users should never see a blank chat after refresh.
B. Queue & Processing State Panel
A persistent, lightweight status area (could be a collapsible panel, sidebar section, or header bar) showing:
This gives the user:
C. Activity Feed / Event Log
A scrollable event log (like a terminal or CI/CD pipeline view) that shows real-time events:
This is different from the chat view — it's a machine-readable audit trail that power users can glance at to understand exactly what happened, especially after a refresh.
D. Reconnection Resilience
When the WebSocket reconnects (after refresh, network drop, or tab wake):
E. Keyboard Shortcut Guard
Optionally intercept F5/Ctrl+R with a confirmation dialog when the agent is actively processing:
This is a common pattern in web apps with unsaved state (Google Docs, Figma, etc.).
Implementation Notes
sessions.historymethod can fetch it on reconnectcollectqueue state (already shown in session_status)Environment