The key points
- Do not ship, book or grant access on authorized alone.
- Auto-capture applies to Orders API payments, and an order can override the dashboard setting.
- payment.captured can arrive before payment.authorized. Fetch the payment before you act.
- A failed event followed by a captured event is a known UPI retry. Do not treat the failure as final.
What does each Razorpay payment state mean?
Razorpay's Standard Checkout guide separates the states. Created means the order exists and the customer has not paid. Authorized means the customer completed payment and the funds are held. Captured means the money is confirmed and queued for settlement, which is when you deliver. Failed means you do not deliver. Refunded means the money has gone back.
The same page says an authorized payment is not yet in your account. You capture it, or you turn on automatic capture, before the capture window ends. Uncaptured payments are refunded. The window itself is a setting in the dashboard, so read the value on your own account before you rely on a manual capture job.
Why do payments sit on authorized?
The usual cause is manual capture with nobody calling the capture API. Capture settings work when the payment was created with the Orders API. A payment without an order id does not follow those settings. If the order itself was created with manual capture, that overrides a dashboard set to automatic.
Turn automatic capture on under Account and Settings, Payment Capture, unless a human must check the order before you take the money. For a single order that should differ, pass the capture mode when you create the order. The guide says the Orders API setting wins over the dashboard. The short window also rules out authorisation as a way to hold a date for weeks, as explained in how a venue should hold a date and take a deposit.
Which webhook should mark the order as paid?
payment.captured, or order.paid. Razorpay's payments webhook reference says payment.captured fires when the payment is captured, and order.paid fires when the order status becomes paid. payment.authorized is the start of the pipeline, not the signal to fulfil. The payload of an event is a snapshot of that moment: a payment.authorized body can describe the authorized state even if the payment has already moved on to captured by the time you read it.
So the handler does not trust the event name alone. It reads the payment id, then fetches the payment and acts on the status Razorpay returns now. That is the same discipline as Stripe webhooks and idempotency: one event id is processed once, and a late or repeated event cannot deliver the order twice. Store the event id before you do the work. Creating the webhook, verifying its signature and handling retries are covered in setting up Razorpay webhooks so no payment is missed.
What if the events arrive in the wrong order?
payment.captured may arrive before payment.authorized. A payment.failed may be followed by payment.captured for the same attempt, because a UPI app can offer an immediate retry after a wrong PIN or a low balance. Razorpay documents both. If your system marks the order dead on the first failure, the successful retry never grants the booking or the download.
Fetch the payment, and if you use orders, the order. Deliver when the fetched status is captured or the order is paid. Ignore an older failure once a capture exists. Show the customer a retry when the fetched status is failed and no capture follows. Taking UPI and card payments on a site covers the checkout; the handling above starts once the customer has paid.
How does Softivum wire this?
The order is created on your server with the capture mode you chose. The browser never tells you that a payment succeeded. The webhook hits an HTTPS endpoint, the signature is checked, the event id is stored, and the payment is fetched before any stock, booking or access changes. Workflow automation is the right shape when the capture has to update a store, a CRM and a WhatsApp confirmation together. The Razorpay account stays in your name.
What to do at each Razorpay payment state
| State | Meaning | What you do |
|---|---|---|
| created | Order exists, customer has not paid | Send the customer to checkout |
| authorized | Funds are held, not settled | Capture, or wait for auto-capture. Do not deliver |
| captured | Confirmed for settlement | Deliver, once, after you have fetched this status |
| failed | That attempt did not complete | Do not deliver. Allow a retry |
| refunded | Money returned | Reverse the delivery if you already made it |
Before you go live with Razorpay
- Orders API is in use, and the capture mode is the one you intend
- Automatic capture is on, or a job calls the capture API inside the window
- Fulfilment runs on fetched status, not on the browser redirect
- The webhook checks the signature and stores the event id
- A failed event does not block a later capture for the same payment
Sources
Rules and guidance this answer relies on. Policies change, so check the current version before acting on it.
