GlossaryDevelopment

Webhook

Also called: HTTP callback, event notification

Definition

An automated message one system sends to another, usually as an HTTP request to a URL you provide, the moment a specific event happens, such as a payment succeeding, a document being signed or an identity check finishing.

How webhooks work

With a normal API integration, your system asks another system for information. With a webhook, the other system tells you when something changes. You register an endpoint, a URL on your server, and choose which events you want. When one occurs, the provider sends a request with details about the event, and your system reacts.

Webhooks are how most modern services report asynchronous results. A payment can fail days after it was started, a signer may complete a document tomorrow and a verification may need manual review. Polling for those changes is slow and wasteful; webhooks deliver them as they happen.

Most providers retry failed deliveries for a period, and many let you replay past events from a dashboard, which helps when recovering from an outage.

Why it matters for your website or product

Webhooks keep your product's records in sync with reality. If you miss the event that says a payment was returned or a KYC check was flagged, your system shows the wrong status and your team acts on bad information. Because webhooks arrive over the public internet, the endpoint must also be secured, or anyone could send fake events.

A product that handles webhooks well feels instant: a status changes the moment something happens, with no one refreshing a page or emailing support.

How we handle it

Every webhook endpoint we build verifies the provider's signature, responds quickly, and hands the work to a queue so slow processing never causes timeouts. Handlers are idempotent, since providers can send the same event more than once, and every event is logged so it can be replayed. We alert on repeated failures instead of letting them pass silently. See web app development and AI and automation.

Example

Imagine a subscription business using Stripe. When a customer's card renewal fails, Stripe sends an invoice payment failed event to the company's webhook endpoint. The app marks the account past due, emails the customer a link to update their card and creates a task for the support team.

Common mistakes

  • Skipping signature verification, so the endpoint accepts forged events.
  • Processing the event before responding, which causes timeouts and duplicate retries.
  • Assuming each event arrives once and in order.
  • Having no logging or replay, so missed events are lost for good.

Questions, answered

Still deciding? Book a 30-minute call.

  • An API is something your system calls to request data or trigger an action, while a webhook is a call another system makes to you when an event happens. APIs are pull; webhooks are push. Most integrations use both: the API to start something, such as a payment, and webhooks to learn how it turned out.

  • Webhooks are secure when the receiving endpoint is built correctly. That means using HTTPS, verifying the provider's signature on every request, rejecting stale or replayed messages and never trusting event data without checking it. Many teams also fetch the latest state from the provider's API before taking sensitive actions, rather than relying only on the webhook body.

Start building this week

Subscribe online in a minute, or talk it through on a call first.