# NoLag > Real-time messaging infrastructure as a service. Build scalable pub/sub applications with WebSocket, presence tracking, and QoS support. ## Docs - [NoLag Documentation](https://nolag.app/docs.md): Build realtime apps with NoLag: pub/sub topics, rooms, presence, QoS delivery, and webhooks, or coordinate AI agents. SDKs for JavaScript, Go, and Python. - [AI Agents](https://nolag.app/docs/agents.md): NoLag is the realtime coordination layer for AI agents: dispatch work, share state, observe decisions, and gate actions. Works alongside LangGraph, CrewAI, and AutoGen. - [Blueprint Composition for Agents](https://nolag.app/docs/agents/composition.md): How to compose the agents Blueprint with chat, notify, track, and other Blueprints via cross-app actor access. - [Agent Examples](https://nolag.app/docs/agents/examples.md): Canonical recipes for common agent workflows: agentic chatbot, autonomous workflow, copilot, compliance, tool-augmented agent, and monitoring. - [Getting Started with AI Agents](https://nolag.app/docs/agents/getting-started.md): Step-by-step guide to building your first multi-agent workflow with @nolag/agents. - [MCP Setup for AI Agents](https://nolag.app/docs/agents/mcp-setup.md): How to connect Claude Desktop, Cursor, or any MCP client to NoLag for AI agent infrastructure management. - [Agent Coordination Patterns](https://nolag.app/docs/agents/patterns.md): Deep dive on the six coordination patterns in @nolag/agents: Handoff, Inbox, Blackboard, Observe, Approve, and Tools. - [Tag Vocabulary for Agents](https://nolag.app/docs/agents/tags.md): Reference guide for capability, priority, status, and custom tags in @nolag/agents. - [API Reference](https://nolag.app/docs/api-reference.md): Complete REST API reference for NoLag. Manage apps, rooms, actors, and more programmatically. - [Error Reference](https://nolag.app/docs/api-reference/errors.md): Complete reference for NoLag REST API and WebSocket errors, status codes, and error handling. - [WebSocket API Reference](https://nolag.app/docs/api-reference/websocket.md): Complete WebSocket API reference for NoLag real-time communication. Covers connection, authentication, message types, presence, lobbies, and reconnection. - [Authentication](https://nolag.app/docs/authentication.md): Learn how to authenticate with NoLag using access tokens and API keys. - [Client Tokens](https://nolag.app/docs/client-tokens.md): Authenticate browsers and mobile apps with short-lived JWTs minted by your backend, so long-lived access tokens never leave your servers. - [Core Concepts](https://nolag.app/docs/concepts.md): The building blocks of NoLag realtime infrastructure: project hierarchy, topics and pub/sub, rooms, presence, lobbies, filters, quality of service, webhooks, and access control. - [Access Control](https://nolag.app/docs/concepts/acl.md): Learn how to configure fine-grained access control for NoLag topics. - [Topic Filters](https://nolag.app/docs/concepts/filters.md): Learn how to use topic filters to narrow message delivery to specific entities. Subscribe with filters, manage them dynamically, and publish to filtered subscribers. - [Project Hierarchy](https://nolag.app/docs/concepts/hierarchy.md): Understand how Projects, Apps, Rooms, and Topics work together to organize your real-time infrastructure. - [Lobbies](https://nolag.app/docs/concepts/lobbies.md): Learn how to use Lobbies in NoLag to observe presence across multiple rooms. Build dashboards that monitor all active sessions in real-time. - [Presence Tracking](https://nolag.app/docs/concepts/presence.md): Track presence in real-time with NoLag. Know who is online, handle join/leave events, discover backend workers and AI agents by capability, and keep scaled-to-zero actors addressable with Persistent Presence. - [Quality of Service (QoS)](https://nolag.app/docs/concepts/qos.md): Learn about NoLag QoS levels: at-most-once, at-least-once, and exactly-once message delivery guarantees. - [Rooms](https://nolag.app/docs/concepts/rooms.md): Learn about NoLag rooms for organizing topics and managing message namespaces. - [Topics & Pub/Sub](https://nolag.app/docs/concepts/topics.md): Learn about NoLag topics and the pub/sub messaging model. Understand topic patterns, wildcards, and message routing. - [Webhooks](https://nolag.app/docs/concepts/webhooks.md): Learn how to use NoLag webhooks for hydration and triggers to integrate with external systems. - [Getting Started](https://nolag.app/docs/getting-started.md): Get started with NoLag in 5 minutes. Learn how to connect, subscribe to topics, and publish messages. - [Guides](https://nolag.app/docs/guides.md): Step-by-step guides to building real-time apps with NoLag: chat, notifications, live dashboards, and IoT tracking. - [Building a Chat App](https://nolag.app/docs/guides/chat-app.md): Step-by-step guide to building a real-time chat application with NoLag. - [Live Dashboards](https://nolag.app/docs/guides/dashboards.md): Build real-time dashboards and live data visualizations with NoLag. - [IoT & Tracking](https://nolag.app/docs/guides/iot.md): Build IoT applications and real-time tracking systems with NoLag. - [Real-time Notifications](https://nolag.app/docs/guides/notifications.md): Build real-time notification systems with NoLag. - [High-Level SDKs](https://nolag.app/docs/high-level-sdks.md): Domain-specific SDKs built on @nolag/js-sdk. Purpose-built APIs for chat, notifications, streaming, IoT, collaboration, and more. - [Chat SDK](https://nolag.app/docs/high-level-sdks/chat.md): Multi-room chat with presence, typing indicators, message replay, and user mapping. - [Collab SDK](https://nolag.app/docs/high-level-sdks/collab.md): Real-time collaboration with operations, cursor tracking, and idle awareness for editors and canvases. - [Dash SDK](https://nolag.app/docs/high-level-sdks/dash.md): Live dashboards with real-time metrics, time-series aggregation, and widgets. - [Feed SDK](https://nolag.app/docs/high-level-sdks/feed.md): Activity feeds with posts, likes, comments, and fan-out delivery. - [IoT SDK](https://nolag.app/docs/high-level-sdks/iot.md): IoT device telemetry and command dispatch with acknowledgment tracking for connected device fleets. - [Notify SDK](https://nolag.app/docs/high-level-sdks/notify.md): Real-time notifications with channels, read/unread tracking, and badge counts. - [Queue SDK](https://nolag.app/docs/high-level-sdks/queue.md): Real-time job queues with lifecycle tracking, progress updates, and worker management. - [Signal SDK](https://nolag.app/docs/high-level-sdks/signal.md): WebRTC signalling over NoLag: peer discovery, offer/answer exchange, and ICE candidate relay. - [Stream SDK](https://nolag.app/docs/high-level-sdks/stream.md): Live streaming engagement with comments, reactions, and polls. - [Sync SDK](https://nolag.app/docs/high-level-sdks/sync.md): Real-time data sync with document CRUD, version tracking, and conflict resolution across clients. - [Track SDK](https://nolag.app/docs/high-level-sdks/track.md): Vehicle and asset GPS tracking with geofencing and location history. Real-time tracking for fleets, delivery drivers, drones, and any moving asset. - [Voice SDK](https://nolag.app/docs/high-level-sdks/voice.md): Turn a live phone call into a NoLag room: stream its transcript as it happens and steer the agent mid-conversation. - [Installation](https://nolag.app/docs/installation.md): Install NoLag SDKs for JavaScript, Python, and Go. - [Wire Protocol](https://nolag.app/docs/protocol.md): NoLag uses MessagePack-encoded maps over WebSocket binary frames. Every message has a type field and topic-specific data. - [Access Scopes](https://nolag.app/docs/scopes.md): Access Scopes give NoLag tenant isolation through topic namespacing. Learn the model, create scopes, assign actors, and build multi-tenant apps with no SDK changes. - [Access Scopes - API Reference](https://nolag.app/docs/scopes/api-reference.md): Complete API reference for Access Scopes endpoints. Create, list, get, update, and delete scopes. List actors assigned to a scope. - [Access Scopes - How They Work](https://nolag.app/docs/scopes/concepts.md): Understand how Access Scopes provide tenant isolation through topic namespacing. Learn the data model, key rules, and why no SDK changes are needed. - [Access Scopes - Getting Started](https://nolag.app/docs/scopes/getting-started.md): Quickstart guide to Access Scopes for tenant isolation in NoLag. Create scopes, assign actors, and verify communication isolation. - [Multi-Tenant Patterns with Access Scopes](https://nolag.app/docs/scopes/multi-tenancy.md): Build multi-tenant applications with Access Scopes. Patterns for tenant isolation, environment separation, team partitioning, and agent multi-tenancy. - [SDKs](https://nolag.app/docs/sdks.md): Official NoLag SDKs for JavaScript, Python, and Go. Full documentation and examples. - [Go SDK](https://nolag.app/docs/sdks/go.md): Complete reference for the NoLag Go SDK. Connect, subscribe, publish, and manage real-time messaging with idiomatic Go patterns. - [JavaScript SDK](https://nolag.app/docs/sdks/javascript.md): Complete reference for the @nolag/js-sdk SDK. Connect, subscribe, publish, and manage real-time messaging in JavaScript and TypeScript. - [Python SDK](https://nolag.app/docs/sdks/python.md): Complete reference for the NoLag Python SDK. Connect, subscribe, publish, and manage real-time messaging with async/await support. - [React Native SDK](https://nolag.app/docs/sdks/react-native.md): React Native bindings for the NoLag core SDK: AppState lifecycle, NetInfo reachability, token caching and polyfills. - [Voice Engine SDK](https://nolag.app/docs/sdks/voice-engine.md): Real-time voice agent engine: turn taking, barge-in, voice activity detection, filler speech and call-screener handling, independent of any telephony or AI vendor. - [Self-Hosting](https://nolag.app/docs/self-hosting.md): Run NoLag yourself. Three ways: the whole stack on your own machine, your broker with NoLag as the control plane, or fully hosted. Both kraken and nolag-core are Apache 2.0. ## Compare - [NoLag vs Ably](https://nolag.app/compare/ably.md): NoLag vs Ably: both are realtime pub/sub platforms with presence. NoLag adds a coordination layer for AI agents and ready-made high-level SDKs so you ship features faster. - [NoLag with AutoGen](https://nolag.app/compare/autogen.md): Use NoLag as the realtime coordination layer under AutoGen. Give multi-agent conversations shared state, task handoff, live observation, and human approval gates. - [NoLag vs Convex](https://nolag.app/compare/convex.md): NoLag vs Convex: Convex is a reactive backend with a built-in database and TypeScript functions. NoLag is dedicated realtime messaging infrastructure with blueprint SDKs and a coordination layer for AI agents. - [NoLag with CrewAI](https://nolag.app/compare/crewai.md): Use NoLag as the realtime coordination layer under CrewAI. Give your crew shared state, task handoff, live observation, and human approval gates across processes. - [NoLag vs Firebase](https://nolag.app/compare/firebase.md): NoLag vs Firebase: Firebase syncs data through Realtime Database and Firestore listeners. NoLag is dedicated realtime pub/sub messaging with blueprint SDKs and a coordination layer for AI agents. - [NoLag with LangGraph](https://nolag.app/compare/langgraph.md): Use NoLag as the realtime coordination layer under LangGraph. Let agents share state, hand off tasks, stream decisions to a UI, and gate actions with human approval. - [NoLag vs Liveblocks](https://nolag.app/compare/liveblocks.md): NoLag vs Liveblocks: Liveblocks specialises in collaborative editing with presence and conflict-free state. NoLag is general realtime messaging infrastructure with blueprint SDKs and a coordination layer for AI agents. - [NoLag vs PubNub](https://nolag.app/compare/pubnub.md): NoLag vs PubNub: both deliver realtime messaging at scale. NoLag adds a coordination layer for AI agents and blueprint SDKs for chat, notifications, and dashboards. - [NoLag vs Pusher](https://nolag.app/compare/pusher.md): NoLag vs Pusher: both add realtime pub/sub to your app. NoLag also gives you AI-agent coordination and ready-made high-level SDKs for chat, notifications, and dashboards. - [NoLag vs Socket.io](https://nolag.app/compare/socketio.md): NoLag vs Socket.io: Socket.io is a self-hosted realtime library you run and scale yourself. NoLag is managed realtime infrastructure with presence, QoS, blueprint SDKs, and a coordination layer for AI agents. - [NoLag vs Supabase Realtime](https://nolag.app/compare/supabase.md): NoLag vs Supabase Realtime: both give you realtime over WebSocket. Supabase ties realtime to a Postgres backend; NoLag is dedicated realtime infrastructure with blueprint SDKs and a coordination layer for AI agents. ## Blog - [Add Realtime to a Next.js App with NoLag](https://nolag.app/blog/add-realtime-to-nextjs.md): A step-by-step guide to adding realtime messaging to a Next.js app with NoLag, including a server route that mints tokens so your API key never reaches the browser. - [Add Realtime to a React App with NoLag](https://nolag.app/blog/add-realtime-to-react.md): How to add realtime messaging to any React app with NoLag using a small reusable hook that handles connect, subscribe, and cleanup. - [Blueprint SDKs vs Raw Pub/Sub: Ship in Minutes Instead of Weeks](https://nolag.app/blog/blueprint-sdks-vs-raw-pubsub.md): Every real-time app rebuilds the same plumbing: rooms, presence, typing indicators, replay, reconnection state, unread counts. Blueprint SDKs give you a domain-specific API so you can skip the wiring entirely. - [How to Build a Real-Time Chat App in Under 10 Minutes](https://nolag.app/blog/build-chat-app-in-minutes.md): Step-by-step tutorial: install the NoLag chat SDK, connect with a token, join a room, send messages, show typing indicators, and display online users. - [Building an Agentic Chatbot with NoLag](https://nolag.app/blog/building-agentic-chatbot.md): Step-by-step tutorial: combine @nolag/chat for the user-facing interface with @nolag/agents for AI-powered responses. Full code walkthrough. - [Connect Your Local LLM to NoLag in 5 Minutes](https://nolag.app/blog/connect-local-llm.md): Wire up Ollama as a NoLag worker agent in under 5 minutes. No framework, no boilerplate -- just a transport layer between your model and the rest of your system. - [Coordinate LangChain Agents with NoLag](https://nolag.app/blog/coordinate-langchain-agents-with-nolag.md): Use NoLag as the coordination layer for LangChain agents. Dispatch tasks to workers, collect results, and keep a human in the loop, over realtime pub/sub. - [From Human Realtime to Agent Realtime](https://nolag.app/blog/human-to-agent-realtime.md): How NoLag's real-time messaging infrastructure maps to agent coordination. The design decisions behind each pattern and performance characteristics for agent workloads. - [Hybrid LLM Coordination: Mixing Local and Proprietary Models](https://nolag.app/blog/hybrid-llm-orchestration.md): Route tasks to the right model: local LLMs for speed and privacy, proprietary APIs for reasoning. NoLag coordinates the handoffs without coupling your agents to any single provider. - [IoT Fleet Tracking Over WebSockets: Architecture for 100K Devices](https://nolag.app/blog/iot-fleet-tracking-websockets.md): GPS trackers, sensors, and connected vehicles generate a constant stream of telemetry. Learn how to architect a fleet tracking system that scales to 100,000 devices with WebSockets, filtered subscriptions, and smart QoS choices. - [MessagePack vs JSON: 47% Smaller Payloads for Real-Time Apps](https://nolag.app/blog/messagepack-vs-json.md): MessagePack produces payloads 30-50% smaller than JSON with no Base64 overhead. Learn when binary serialization matters for real-time apps and how NoLag uses it. - [Migrate from Ably to NoLag](https://nolag.app/blog/migrate-from-ably-to-nolag.md): A practical guide to moving a realtime app from Ably to NoLag, with a concept map and before-and-after code for channels, publishing, presence, and history. - [Migrate from Firebase to NoLag](https://nolag.app/blog/migrate-from-firebase-to-nolag.md): How to move the realtime layer of a Firebase app to NoLag, when it makes sense, and what to keep. Includes a concept map and before-and-after code. - [Migrate from Pusher to NoLag](https://nolag.app/blog/migrate-from-pusher-to-nolag.md): A practical guide to moving a realtime app from Pusher Channels to NoLag, with a concept map and before-and-after code for subscribing and publishing. - [Why Multi-Agent Systems Need a Coordination Layer](https://nolag.app/blog/multi-agent-coordination-layer.md): Multi-agent AI systems need more than an LLM API. They need coordination infrastructure: task dispatch, shared state, approval gates, and observability. Here is why pub/sub is the right primitive. - [Stop Buying Realtime One Scenario at a Time](https://nolag.app/blog/one-connection-many-realtime-features.md): Chat from one vendor, notifications from another, dashboards hand-rolled, telemetry over MQTT, a queue for agent tasks. NoLag is realtime messaging infrastructure and a coordination layer for AI agents, with a Blueprint per scenario, so all of it runs on one connection per tenant. - [Building Presence at Scale: Who Is Online and How to Track It](https://nolag.app/blog/presence-tracking-at-scale.md): Presence tracking looks simple until you have 10,000 concurrent users across hundreds of rooms. Learn the architecture behind scalable online/offline status, heartbeat timeouts, and per-room vs global presence. - [The Pub/Sub Pattern Explained: Topics, Rooms, and Message Routing](https://nolag.app/blog/pubsub-pattern-explained.md): Understand publish/subscribe from first principles. Learn how topics, rooms, and filters route messages at scale, and how NoLag models real-time apps with apps, rooms, and topics. - [QoS 0, 1, and 2: Choosing the Right Delivery Guarantee for Every Message](https://nolag.app/blog/qos-levels-real-time-messaging.md): Learn what QoS 0, 1, and 2 mean in real-time messaging. At most once, at least once, and exactly once delivery, with practical guidance on which to use for telemetry, chat, and payments. - [Real-Time Dashboards Without the Firehose: Filtered Subscriptions](https://nolag.app/blog/real-time-dashboard-filters.md): Most dashboards show a subset of data, but most pub/sub systems deliver everything. Learn how topic filters subscribe only to the entities on screen, saving bandwidth and keeping UIs snappy. - [Handling Disconnects Gracefully: Reconnection and Message Replay](https://nolag.app/blog/reconnection-message-replay.md): Mobile networks drop, Wi-Fi switches, laptops close. Learn how reconnection and message replay keep real-time apps consistent when connections fail, without flooding users with stale notifications. - [Building a Voice AI Agent That Can Actually Do Things](https://nolag.app/blog/voice-agent-with-tools-twilio.md): A voice agent has about a second to reply, so the model answering the phone is small and has no tools. Here is how to give it real capability over NoLag: a Twilio call becomes a coordination room, and a larger orchestrator answers asynchronously while the caller keeps talking. - [WebSockets vs Polling: Why Real-Time Apps Need a Persistent Connection](https://nolag.app/blog/websocket-vs-polling.md): Compare HTTP polling, long polling, server-sent events, and WebSockets. Learn why persistent connections win for real-time apps and when polling is still fine.