A mobile-first chat UI for OpenClaw — the open-source AI agent platform. Built with Next.js, Tailwind CSS v4, and zero UI dependencies.
- Real-time streaming — word-by-word text streaming with animated cursor
- Rich markdown — headings, lists, tables, code blocks with syntax labels and copy button
- Tool calls — live tool execution with running/success/error lifecycle
- Thinking/reasoning — expandable reasoning blocks on assistant messages
- Command palette — slide-up sheet with all OpenClaw slash commands, search and autocomplete
- Demo mode — fully functional without a backend server
- Mobile-first — optimized for iOS Safari with pull-to-refresh, viewport fixes, and smooth scroll animations
- Dark mode — automatic theme via CSS custom properties
git clone https://github.com/user/mobileclaw.git
cd mobileclaw
npm install
npm run devOpen http://localhost:3000.
Try the UI without a backend:
- Visit
localhost:3000?demo— auto-enters demo mode with sample conversation - Or open the app, leave the URL field empty, and click "Start Demo"
In demo mode, send messages with these keywords to see different features:
| Keyword | What it shows |
|---|---|
weather |
Tool call with JSON result |
code / function |
Syntax-highlighted code blocks |
think / reason |
Expandable reasoning block |
error |
Failed tool call |
help |
List of demo commands |
- Start your OpenClaw instance
- Open MobileClaw and enter the server URL (e.g.
ws://127.0.0.1:18789) - Optionally enter a gateway auth token
- Click Connect
The connection persists across page reloads via localStorage.
- Next.js 16 — App Router, single-page architecture
- Tailwind CSS v4 — utility-first styling with OKLch color tokens
- TypeScript — type-safe WebSocket protocol handling
- Zero UI dependencies — no component library, hand-rolled components with inline SVG icons
The entire UI lives in a single file (app/page.tsx) — this is intentional for rapid iteration. Supporting modules:
| File | Purpose |
|---|---|
app/page.tsx |
All components, state, and rendering |
lib/useWebSocket.ts |
WebSocket hook with auto-reconnect |
lib/toolDisplay.ts |
Tool name → human-friendly label mapping |
lib/demoMode.ts |
Demo mode handler with mock data |
app/globals.css |
Tailwind config and OKLch color tokens |
- Read
CLAUDE.mdfor project conventions - Read
AGENTS.mdfor architecture details - Test changes in demo mode (
?demo) before testing with a live server - Run
npm run buildto verify no build errors