Hyperswitch smart retries

How Hyperswitch smart retries decide whether a failed payment is retried, on which path, and what your team must configure and verify before turning them on.

On this page

When Hyperswitch smart retries recover failed payments

Hyperswitch smart retries re-attempt a declined payment automatically, so a self-hosted team can recover some failures without asking the customer to start again. A team needs them when declines are costing revenue and the causes are mixed: some are temporary processor problems, some need the customer to authenticate again, and some come from a debit route that a signature network can complete. Hyperswitch documents four strategies. Cascading sends the payment to an alternate processor. Step-up retry repeats the attempt with additional authentication. Clear PAN retry sends the raw card number when de-tokenisation fails. Global network retry moves a payment to a signature network after a debit network failure.

Which strategy runs for a given decline depends on how Hyperswitch classifies the processor's error codes. Each processor's codes are marked as retriable or non-retriable and mapped to a retry type, and the Hyperswitch docs say processors have between 400 and 1,000 or more error codes. That mapping is the first thing to review. Ask your processors which codes they return for soft declines, authentication requirements and network failures, then confirm with Hyperswitch how those codes are mapped before you assume a decline will be retried.

Retries also need explicit merchant configuration. You must enable each retry flow you want and set N, the number of retries permitted. Start with a small N and a narrow set of flows, then check the effect on authorization rates, customer abandonment and processor fees against your own baseline. Confirm the exact configuration keys and limits for your Hyperswitch version in the Hyperswitch smart retries docs before you plan the rollout.

How a failed payment moves through the retry decision

The flow starts when the processor returns an authorization decline. Hyperswitch checks the processor's error code against its retriable or non-retriable mapping, and only retriable codes reach the retry branches. Each branch is gated by the retry flows the merchant has enabled and by the retry count N that the merchant sets, so check both before go-live. A decline that no enabled branch can handle ends as a final decline.

Retry branches open only for retriable codes, enabled flows and the configured retry count.

What each of the four retry strategies does

Hyperswitch smart retries treat a failed payment as a classification problem: the error code decides whether a retry is allowed and which kind. Each strategy below fires on a different failure, carries a different cost or customer-experience trade-off, and depends on processor behavior your team has to confirm before enabling it.

Cascading retry to an alternate processor

When the first processor declines with an error code classified as retriable, Hyperswitch can send the same payment to a second connector in the routing order. This recovers declines caused by processor-side issues, but every retry is a new authorization attempt, so issuers may see several attempts for one purchase. Confirm with each processor which codes it returns for soft declines, how it reports duplicate attempts, and whether the alternate connector accepts the same stored credentials.

Smart retries docs

Step-up retry with additional authentication

When an issuer requires authentication for a payment that was declined without it, the retry flow can step the payment up to a 3DS challenge and try again. It protects approval rates on authentication-required declines, but the customer must complete a challenge, so abandonment risk rises. Confirm which 3DS path your processors support, how authentication results are passed back, and which customer flows can handle a challenge without a page reload.

Smart retries docs

Clear PAN retry when de-tokenization fails

If the stored token cannot be turned back into card data for a processor, a clear PAN retry sends the card number directly from the vault to that processor. It can rescue saved-card payments that would otherwise fail, but it moves raw card data into a flow that your PCI DSS scope analysis must cover. Confirm that your vault model and processor both permit this flow, and that your team has agreed the data handling before enabling it.

Vault deployment models

Global network retry after a debit network failure

When a debit network routes a transaction and fails, a global network retry sends it again over the signature network for the same card. This can recover declines tied to a single debit network routing path, but the retry runs on a different network with its own fee structure and rules. Confirm with your processor which card brands and regions support signature routing, how the retry changes interchange, and whether the cardholder sees a different descriptor or authorization flow.

Smart retries docs

How error code mapping drives which retry runs

Hyperswitch decides whether a failed payment is eligible for a retry by reading the processor's error code, not the generic decline message. Each connector's error codes are classified as retriable or non-retriable, and each retriable code is mapped to one of the retry types: cascading to another processor, step-up with additional authentication, clear PAN retry, or global network retry. The mapping is what turns a decline into a specific action, so it has to be reviewed connector by connector before you rely on smart retries in production.

The volume of codes makes this a review task, not a configuration toggle. The Hyperswitch smart retries docs say processors have between 400 and 1,000 or more error codes each. Start with the codes your processors actually return for your traffic: pull the decline reasons from the last few months of transactions, compare them with each processor's own error code documentation, and confirm for every high-volume code whether Hyperswitch treats it as retriable and which retry type it feeds. Pay particular attention to codes that look similar but carry different meanings, such as issuer-side soft declines and fraud or security blocks, because retrying the wrong kind can damage authorization rates and trigger processor scrutiny.

Verify the mapping with test transactions in a non-production environment before enabling the flows. Use sandbox or test credentials that can produce the specific codes you care about, confirm the retry attempt and the final status recorded for each, and check that the number of attempts respects the N limit you set. Then confirm what happens when a code is not in the mapping. Hyperswitch's behavior for unmapped codes should be verified in the current smart retries documentation and in your own test runs, and your team should record that answer as a standing decision, because new codes appear as processors change and an unmapped code is the most likely source of silent retry gaps.

Configuration options and when each fits

This table compares each smart retry setting Hyperswitch merchants configure, what it controls, when it suits a payments stack, and the trade-off to weigh before turning it on. Read it as a checklist: enable only the flows your processors, vault and card mix can support, then set N to a limit your customers and fraud controls can tolerate.

OptionWhat it controlsWhen it fitsTrade-off to weigh
Enable the retry flowsTurns on each retry type (cascading, step-up, clear PAN, global network) for the merchant profile. Merchants must enable the flows they want before any retry runs.Enable only the flows you have tested against your processors and vault setup, so behavior is predictable in production.Each enabled flow adds a retry path to review in testing and monitoring. Enabling all flows at once makes it harder to tell which path recovered a payment.
Set N, the retry limitSets the number of retries permitted for a payment. Hyperswitch smart retries docs require merchants to set N.Set a low value first, then raise it only where retry data shows recovery without customer or fraud-control friction.Higher N can recover more payments but may add repeated authorization attempts, which some processors and card issuers may flag. Confirm processor limits on repeat attempts.
Choose alternate processors for cascadingDetermines which other connectors a failed payment may be sent to when the first processor declines with a retriable error.Use when you have more than one active connector for the same market and currency, with contracts that allow the traffic.Each alternate processor brings its own fees, settlement, reporting and error code mapping. Confirm each connector's credentials and webhook setup before adding it to the cascade.
Enable step-up retry with 3DS settingsSends a failed payment back through additional authentication, such as 3DS, when the issuer's decline indicates authentication is required.Use for card-not-present flows where your 3DS configuration and SCA rules are already defined and tested.Adds a customer challenge step, which can reduce conversion. Align the step-up rules with your SCA exemption and 3DS settings so retries do not conflict with them.
Enable clear PAN retryRetries using the card data after de-tokenization, which only works when the vault and processor both support it.Use only when your vault model and processor have been confirmed to support clear PAN retry, and your PCI DSS scope has been assessed for it.Handling clear PAN data can expand the cardholder data environment and assessor scope. If the vault or processor does not support it, do not enable the flow.
Enable global network retry for debit cardsRetries a payment on a signature network after a debit network failure.Use for debit card traffic where the signature network route is supported by your connectors and acceptable under your agreements.Signature network routing may carry different fees and interchange than the debit route. Confirm with your processor and finance team before enabling it.
Map processor error codesClassifies each processor's error codes as retriable or non-retriable and links them to the retry types. The docs say processors have between 400 and 1,000 or more error codes.Review the mapping for every connector in the cascade before go-live, and again after processor changes.Incorrect mapping can retry payments that should stop (wasting attempts) or stop payments that should recover. Ask each processor for its current error code list.

Setup sequence for enabling smart retries

This sequence takes a self-hosted Hyperswitch stack from a running deployment to live smart retries, with each retry path enabled deliberately, tested in a sandbox and watched after rollout. The output is a configuration the team can explain, test and monitor for each processor it routes to.

  1. Confirm the deployment and connectors are live

    The platform team confirms that the Router, Scheduler, PostgreSQL, Redis and the card vault run in the target environment, and that each processor connector you plan to retry against is configured and returns test authorizations. Check the Control Center and the health endpoints for each service, and record which connectors are active. Smart retries cannot be tested against a processor that is not yet connected, so this step closes only when every planned connector completes a test payment end to end.

  2. Review error code mappings for each processor

    The payments engineer and risk owner export the error code mapping that Hyperswitch uses for each processor and check how each code is classified as retriable or non-retriable and which retry type it maps to. Processors can expose hundreds of codes, so start with the codes your historical declines produce most often, and confirm that unfamiliar codes are not silently treated as retriable. The step is done when a reviewed list exists for every connector, with owners and the date of the review.

  3. Enable only the retry flows you need

    The merchant administrator turns on the retry flows that match the business case in the merchant configuration, such as cascading to an alternate processor, step-up with additional authentication, clear PAN retry or global network retry on a signature network. Each flow changes how customers and processors experience a decline, so enable one flow at a time and record the reason for each. The step is complete when the configuration export matches the approved list and any flow left off is recorded as deliberately excluded.

  4. Set the retry limit N

    The payments lead sets N, the number of retries permitted, separately for the flows enabled in the previous step, and confirms the value with the risk and customer experience owners. A higher limit increases the number of attempts made on a declined payment, so the value should reflect the approved policy rather than a default. The check is a saved configuration showing the agreed N for each flow and a short written rationale that an auditor or internal reviewer can read.

  5. Test each retry path in a sandbox

    The QA engineer runs test transactions for every enabled retry path in a sandbox that uses the same connector configuration as production, including declines that trigger each classification. Confirm that each attempt is recorded with the expected retry type, that the retry stops at N, and that non-retriable declines are not retried. Keep the test payment identifiers and the observed results, because the same evidence is what the team will compare against after rollout. The step closes when every path has a passing record and no retry exceeds the limit.

  6. Roll out with retry outcome monitoring

    The operations team enables the configuration in production for a limited set of traffic first, then widens the scope once retry outcomes match the sandbox results. Dashboards should show attempts per retry type, recovery rate per processor, declines after the final retry and any increase in customer abandonment after a step-up challenge. Define alert thresholds with the business owner before go-live so that a change in retry behavior prompts a review. The sequence is complete when monitoring is live, alerts reach an owner and the first review of retry outcomes is scheduled.

Questions teams ask before enabling retries

Can our team configure Hyperswitch smart retries without outside help?

Yes, a team with payments and platform engineering skills can enable retries in its own environment, but the work is larger than flipping a setting. Each retry flow must be turned on for the merchant profile, and the number of permitted retries, N, must be set deliberately. The harder part is reviewing each processor's error codes, since Hyperswitch classifies them as retriable or non-retriable and maps them to retry types. Processors can have between 400 and 1,000 or more error codes, so the review effort grows with the number of processors you connect. Check the Hyperswitch smart retries docs before deciding who owns each step.

What drives the cost of configuring retries in-house versus with a partner?

The cost comes from the people hours spent on configuration, error code review, testing and operations, plus any internal time lost to failed payments while the work is in progress. In-house cost depends on how many engineers already know the processors and how much of the error code mapping they need to learn. A partner's cost follows from a written scope that lists the processors, retry flows, environments and test coverage. Costs that recur include reviewing new error codes when processors change and monitoring retry outcomes after go-live. Ask any provider to separate one-time configuration from ongoing support in the quote.

How does the number of processors affect validation time?

Validation time grows mainly with the number of processors and the error codes each one returns. Every processor needs its codes reviewed, its retriable and non-retriable classifications checked, and its retry paths tested against the flows you enabled. Cascading retries also depend on how many alternate processors are eligible for each merchant, so each added route is another path to test. Step-up 3DS and global network retries add scenarios that depend on your authentication setup and card mix. Ask for the validation plan to list processors, flows and test cases so you can compare effort directly.

What must our team supply before retry configuration starts?

Three inputs drive most of the early work. First, processor credentials for each connector you plan to use in a sandbox or test environment. Second, a review of the error codes each processor returns, with your team's decision on which should be retried and which should stop. Third, test cards that trigger the declines you want to exercise, such as those used for insufficient funds or authentication required responses. Your team should also decide the retry limit N and which retry flows the business accepts. Missing any of these inputs usually extends the schedule, so gather them before the work is scoped.

How do retries interact with PCI DSS scope and the vault model?

Retries themselves do not remove card data from your scope, and the vault model you choose decides how much of the card path your systems touch. Clear PAN retry depends on de-tokenisation, so the vault design determines whether that path exists and who handles the card data when it runs. In the self-hosted, in-house PCI model, the Hyperswitch docs state that the merchant is fully responsible for PCI DSS certification and data handling. With an external PCI vault provider or the SaaS Hyperswitch Vault, the scope may differ. Confirm the vault model and retry flows with your QSA before enabling clear PAN retry. DeployOpen prepares systems and evidence for compliance assessments, but it does not issue audit reports or certifications.

Which error codes do we need to review before turning on retries?

Review every error code that your traffic actually produces, starting with the processors that carry the most volume. For each code, confirm whether Hyperswitch classifies it as retriable or non-retriable and which retry type it maps to. Pay closest attention to codes that could lead to a duplicate charge, such as ambiguous network responses, and to codes that signal authentication requirements, since they drive step-up 3DS. Document each decision with the business reason, so auditors and future engineers can trace it. Because processors can have hundreds or more codes, prioritize by observed frequency and revisit the mapping after processor updates.

What should we check after retries go live?

Start by checking that retries fire only for the codes you approved and that the retry count never exceeds N. Then compare authorization outcomes before and after go-live for each processor, and look for any rise in duplicate or unexpected charges. Confirm that step-up 3DS and global network retries behave as your authentication and card mix expect. Set alerts on retry volume so spikes are noticed quickly. Plan a periodic review of the error code mapping, because processor behavior and Hyperswitch releases can change the classifications your configuration depends on.

Security and operational risks of automatic retries

Automatic retries widen the set of people, services and card data paths that touch a failed payment. The cards below cover the risks that matter most for a self-hosted Hyperswitch deployment, and each one names a check you can run before retry flows go live.

Retries that repeat authentication and consent

A step-up retry can send a customer back into 3DS, and a cascading retry can send the same stored credential to a second processor. Confirm which retry types can repeat an authentication challenge, whether the customer's consent for the original charge covers a retry on another processor, and how your terms describe that. Test each retry path with a declined sandbox card and record which customer-facing messages appear.

Smart retries docs

Clear PAN retry and decryption scope

A clear PAN retry sends unencrypted card data to a processor after de-tokenisation fails, which changes where card data is decrypted and who is in PCI DSS scope. Ask your QSA and your Hyperswitch team which service performs decryption, which network paths carry clear PAN, and whether that path is enabled at all. Disable it unless your assessment covers that flow.

Access control on retry settings

Retry counts, enabled flows and error code mappings are merchant configuration. A user who can raise N or enable a clear PAN flow can change card data exposure and charge frequency without a code change. Limit these settings to named roles in the Control Center, review who holds them, and confirm that SSO group changes do not silently grant them. Roles are managed in Hyperswitch rather than mapped from your identity provider.

Logging and audit of retry decisions

Each retry decision depends on a processor error code mapped to a retriable or non-retriable class. Log the original decline, the code, the retry type chosen and the outcome, and keep those records in your own log store with a defined retention period. Without this trail, you cannot explain to a customer or auditor why a second charge was attempted.

Duplicate charge risk to test

A retry after an ambiguous timeout can create a second authorization if the first one succeeded. Test timeout and webhook delay scenarios in a staging environment, confirm idempotency keys are sent on every attempt, and verify that reconciliation shows one successful capture per order. Ask the vendor and your processors how each handles a duplicate attempt before enabling global network retry.

What changes for your team after go-live

The main ongoing task is reviewing retry outcomes, not just watching whether payments succeed. Hyperswitch classifies each processor's error codes as retriable or non-retriable and maps them to the four retry strategies, so a change on the processor side can quietly shift which declines get retried. When a processor adds a code, renames one or changes how it reports a soft decline, the mapping may send a payment to the wrong path or skip a retry that used to work. Someone on your team should own a recurring review of retry attempts by strategy and by processor, and should compare the results against the period before the change. Ask your partner or Juspay's documentation for the current mapping of each connector you use, and confirm who on your side is expected to update it when a processor changes.

Error mappings also have to survive Hyperswitch upgrades. Each release can add connectors, adjust defaults or change how retry flows are configured, so a mapping you reviewed on one version may not hold on the next. Treat the mapping as versioned configuration: record which overrides you made, why you made them, and which release you tested them against. Before each upgrade, run a test set of failed payments through the retry flows you have enabled, including the merchant setting for the number of retries (N), and confirm the outcomes match what you expect. This check is cheaper to run before production than to reconstruct from customer complaints afterward. Confirm with your partner whether upgrade testing is part of the agreed scope or a separate retainer.

Retries do not act alone. The same failed payment can be affected by intelligent routing, which decides which processor gets the first attempt, and by revenue recovery, which retries failed recurring payments. If a retry sends a payment to a second processor while routing was already set to favor that processor, or a recovery schedule retries a payment that smart retries already retried, your customers may see duplicate attempts and your processor fees may rise. Assign one owner to review these three settings together, and document which component is allowed to act first for each payment type. Any change to routing weights or recovery schedules should trigger a check of retry outcomes on the same day.

How DeployOpen works on this

DeployOpen plans and implements self-hosted open-source platforms inside your own infrastructure, so retry configuration for Hyperswitch smart retries is scoped against your processors, error code mapping and merchant settings before any change is made. The work is delivered as a fixed-scope engagement with written deliverables, followed by optional ongoing support.

How we scope

  • Inventory which processors, retry flows and N retry limits your business needs before configuration starts.
  • Review the processor error code mapping for each connector and agree which codes count as retriable.
  • Record the written scope, deliverables and timeline together so the boundaries of the retry work are agreed in advance.

How we build

  • Enable only the merchant retry flows agreed in scope, and document each setting and its owner.
  • Test cascading, step-up 3DS, clear PAN and global network retries against sandbox or agreed test cases.
  • Confirm retry behavior against your Hyperswitch version, since the docs and release notes change between releases.

How we hand over

  • Deliver a configuration record listing enabled retry types, retry limits, processor mappings and change history.
  • Provide a runbook for reviewing declined payment outcomes, retry results and error code changes after go-live.
  • Train the operations and payments team on where retry settings live in the Control Center and how to request changes.

How we support

  • Offer retainer support for upgrades, processor changes and retry rule adjustments after handover.
  • Retest retry flows after each upgrade or new connector so error code mapping still matches processor behavior.
  • Agree the support scope and response expectations in writing with your team before the retainer starts.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.