# Webhook vs WebSocket: What's the Difference?

A webhook is a stateless HTTP request the source sends to your endpoint when an event happens, best for server-to-server event delivery. A WebSocket is a persistent, two-way connection between a client and a server, best for continuous low-latency interaction like live dashboards, chat, or collaborative editing. They solve different problems: webhooks notify a backend that something happened, WebSockets keep two parties in constant conversation.

## Webhooks vs WebSockets at a glance

|  | Webhooks | WebSockets |
| --- | --- | --- |
| Connection | None; one HTTP request per event | Persistent, kept open |
| Direction | One-way, source to your server | Two-way, full duplex |
| Typical use | Backend integrations, event notifications | Live UI: chat, presence, trading, games |
| State | Stateless | Stateful; you manage the connection lifecycle |
| Scaling concern | Handling delivery volume and retries | Holding many concurrent connections |
| Runs in the browser | No | Yes |

## When to use each

Use webhooks when one backend needs to tell another that an event occurred, especially across organizations.

Use WebSockets when a client needs continuous, bidirectional, low-latency updates during an active session.

## How Hookdeck fits

WebSockets and webhooks often coexist: a WebSocket pushes live updates to a user's browser, while webhooks feed your backend the events those updates are based on. The webhook side is where reliability gets hard, because a dropped event has no open connection to recover it. Hookdeck's Event Gateway receives, queues, retries, and gives you full history for inbound webhooks, so your backend never misses the events driving your live experience. [Explore the Event Gateway](https://hookdeck.com/event-gateway), or inspect real webhook payloads instantly with the free [Console](https://console.hookdeck.com).

## Related questions

* [Webhook vs Server-Sent Events (SSE)](/webhooks/faq/webhook-vs-sse)
* [Webhook vs WebSocket vs SSE](/webhooks/faq/webhook-vs-websocket-vs-sse)
* [Webhook vs API Polling](/webhooks/faq/webhook-vs-api-polling)