Interactive Demo

Server-DrivenReactivity

Watch how irgo + Datastar creates seamless, real-time interactions.
All updates flow from Go handlers via SSE streams.

User Actiondata-on:clickGo Handlerctx.SSE()SSE Streamtext/event-streamDOM MorphIdiomorphPOST requestHTML responsePatch elements

Live Counter

SSE Response

Click the button to trigger a Datastar action. The server responds with an SSE stream that morphs the DOM.

0
Current Count
SSE Event Stream
Go Handler
func Increment(ctx *router.Context) error {    count++    return ctx.SSE().PatchTempl(        templates.Counter(count),    )}
Template
templ Counter(count int) {    <div id="counter-value">        <span>{ strconv.Itoa(count) }</span>    </div>}
Shape morphs smoothly

DOM Morphing

Datastar uses Idiomorph to intelligently update the DOM. Elements morph smoothly instead of being replaced, preserving scroll position, focus, and CSS animations.

Preserves element state
Smooth CSS transitions
No page flicker
Signals syncing...

Reactive Signals

Datastar signals provide client-side reactivity that syncs with server state. Two-way binding keeps your UI and server in perfect harmony.

<div data-signals="{name: '', greeting: ''}">    <input data-bind:name />    <button data-on:click="@post('/greet')">        Say Hello    </button>    <p data-text="$greeting"></p></div>

Real-Time Updates

Server push via SSE hub. Perfect for live dashboards, notifications, and collaborative features.

Live Dashboard

Stream metrics and stats to connected clients

Notifications

Push alerts instantly to specific users

Collaborative

Real-time sync across multiple sessions

Chat

Build chat rooms with just Go and HTML

// Broadcast to all clients in a roomhub.BroadcastToRoom("dashboard",    datastar.PatchElements(html),    datastar.PatchSignals(map[string]any{        "lastUpdate": time.Now().Format(time.RFC3339),    }),)

Ready to Build?

Create your first irgo app in under a minute. Full cross-platform support included.