What A/B testing a Hyperswitch routing change proves before rollout
A live split proves whether a routing change improves approval rates for your traffic before you send all of it through the new logic. Hyperswitch documents six routing strategies: rule-based, volume-based, auth-rate, multi-objective, least cost routing for debit networks, and default fallback routing. Before you design a test, check the Hyperswitch intelligent routing docs and your version's release notes for whether a native experiment feature exists. If none is documented for your version, you will need to split traffic yourself, for example with a percentage rule, and record which arm each payment took.
A control arm keeps the current routing configuration. A variant arm runs the proposed change on a defined share of the same kind of traffic at the same time. Because both arms run in the same period, a live split separates the effect of the routing change from seasonality, processor incidents and promotions. A before-and-after comparison cannot do this, since approval rates move for many reasons over a week or a month. The split must also record the processor, card type and country for each attempt, so you can see which segments the change helped or hurt.
Results depend heavily on volume and mix. A low-volume merchant or a narrow card product may not produce enough attempts for a difference to be distinguishable from noise within a reasonable window, so confirm the minimum sample your analysis method needs before you start. Mix matters too: a variant that wins on domestic debit cards in one country can lose on international credit cards elsewhere. Agree the metrics, the stopping rule and the segments in writing before the split goes live, and confirm with your processors which fields they return so the arms can be compared accurately.
Which routing changes suit A/B testing in Hyperswitch
Not every routing change can be tested fairly on a live split. Some change the whole traffic mix, while others only touch a narrow slice of declined or ineligible payments. The cards below cover the changes teams most often want to prove, the metric that should decide each one, and where a split is hard to read.
Moving to auth-rate routing
The variant sends traffic to the processors with the strongest recent authorization rates instead of a fixed rule order. Authorization rate is the primary metric, but the control and variant must see comparable merchants, currencies and card mixes, or the result reflects segment differences rather than routing. Auth-rate routing also needs enough volume per processor before it learns, so check the minimum volume the docs describe for your version and confirm the strategy setting in the intelligent routing docs before you configure the arms.
Intelligent routing docsChanging a volume split
The variant shifts the percentage of traffic sent to each processor, for example to test a new acquirer during a gradual cutover. Primary metric is authorization rate per processor, with cost and dispute rate as guardrails. Because the split itself changes which processor each payment reaches, compare results within the same segments and watch for time-of-day or seasonal effects that the arms may not share.
Reordering a multi-objective ranking
Multi-objective routing re-ranks processors by processor cost after authorization rate. The variant changes the weighting or the cost inputs, so the primary metric should be net cost per successful payment, paired with authorization rate as a guardrail. Cost is only as accurate as the settlement and invoice data fed into Hyperswitch, so confirm the cost data is current on both arms before reading any difference.
Adding a new processor
The variant adds a processor to the candidate pool, which changes eligibility for every payment that matches the rule. Primary metric is authorization rate on the new processor against the incumbent, measured on comparable traffic. Adding a processor also changes connector behavior such as decline codes and retry handling, so review decline code mapping before the test, not after.
Changing a default fallback order
Default fallback routing applies only when no rule matches or the chosen processor is ineligible, so only a small share of traffic reaches it. A split on this change is hard to isolate, because most payments never touch the fallback and the sample of affected payments may be too thin to read in a reasonable window. Treat it as a targeted test on a known slice, or validate it with a staged rollout and monitor recovery rates on the fallback path.
Enabling least cost routing for debit
The variant routes eligible debit payments over the cheapest local debit network. Primary metric is cost per transaction on debit payments, with authorization rate as the guardrail, because a cheaper network that declines more often can cost more overall. Confirm the connector and dashboard prerequisites for your version, since the arms can only differ on payments that qualify for the network choice.
Configuration options for an A/B testing split
This table compares four ways to build a routing A/B split in a self-hosted Hyperswitch stack: volume-based percentages, a separate merchant or profile per arm, a feature flag that selects the routing configuration, and an external experimentation tool. Read each row for what the option isolates, what leaks between arms, and what attribution data you must capture. The main takeaway is that the cleaner the isolation, the more setup and data work it requires, and the attribution step is where most splits fail.
| Option | Isolates well | Contaminates | Effort and attribution data |
|---|---|---|---|
| Percentage split with volume-based routing | Traffic share per processor on one merchant profile, with a single config to change | Same customers can land in both arms across retries and repeat visits; arms share processor rate limits and fallback order | Low setup. Record the connector chosen and routing rule ID on every attempt, since the split is decided per payment |
| Separate merchant or profile per arm | Routing rules, fallbacks and connector credentials are fully independent per arm | Customers using both arms, shared vault and customer records, and any account-level setting that crosses profiles | Higher setup and duplicate configuration to keep in sync. Assign arm by profile ID on each payment and reconcile per profile |
| Feature flag in checkout or backend | Arm assignment can be sticky per customer or cart, and the flag owner controls timing and rollback | Flag logic bugs can send one customer to both arms; retries may re-evaluate the flag and switch arms mid-payment | Medium to high setup in your code. Pass the arm as metadata on each payment request and store it with the order record |
| External experimentation tool recording arm assignment | Assignment is recorded independently of routing, which helps audit and statistical analysis | Assignment and routing can drift apart if the tool and Hyperswitch disagree on the arm; latency or outage can change routing | Highest integration effort. Confirm whether your routing configuration can be selected per request, which is a capability to verify with the vendor or your environment |
| Capability to confirm before choosing | Whether routing configuration can be selected per payment or per profile in your Hyperswitch version | Whether retries re-enter routing and whether they keep the original arm | Check the routing docs and your version's release notes before committing to an option |
How to set up A/B testing for routing in Hyperswitch
This sequence takes a proposed Hyperswitch routing change from a written hypothesis to a promoted configuration, with a recorded control, a tested variant, guardrails and a planned split in between. Each step closes with a check so the team can show that the results reflect the intended traffic.
Write the hypothesis and primary metric
The payments lead and the routing owner state in writing which change they expect to improve, such as an auth-rate strategy replacing a fixed processor order in one market or card segment (illustrative). They name one primary metric, define how it is calculated from transaction records, and list the secondary metrics that must not get worse. The step is done when finance and risk approve the document and the metric can be reproduced from exported payment data.
Record the current routing configuration as control
The routing owner exports the active routing rules, processor priorities and default fallback order from the Control Center or the routing configuration API, then stores the export with a version label and date. Confirm the export method for your release before relying on it. This stored record is the control arm. The check is that an engineer who was not involved can read the file and confirm it matches the processor order payments follow today.
Build the variant in non-production
The engineering team creates the variant configuration in a staging deployment that runs the same Hyperswitch release and connector set as production. They connect sandbox credentials for each processor the variant can select, then run test payments through every route, including a forced decline that triggers a fallback. The check is that the variant selects the expected processors and that each fallback attempt carries its original attribution in the logs.
Choose the split and population
The team decides the share of eligible traffic sent to each arm and which markets, currencies, card networks and payment methods are included. It also documents exclusions, such as merchant-initiated saved-card payments if the variant does not cover them. Keep one control and one variant so the result stays readable. The check is that the population filter runs as a query over recent data and that the expected volume per arm is estimated from that query before launch.
Assign payments to arms and record them
The team configures the split so each payment is assigned to exactly one arm when it is created. It confirms the field name that stores the arm label and where that label appears in payment data, refunds, retries and webhooks for your version. The check is that sample payments from both arms show the label, and that the label survives a retry and a fallback attempt on the same payment.
Set guardrails and stop rules
The team agrees in writing on guardrail metrics, usually approval rate by processor and card network, fraud-related decline codes, router error rates and latency. Chargeback rates lag, so note how late they arrive. For each guardrail, the team sets a threshold that pauses the variant and names an owner who can route all traffic back to control. The check is that each dashboard panel or alert is live and that a test alert reaches the owner before any live traffic moves.
Run the split for a planned period
The team starts the split and reviews guardrails daily without editing either arm. Every incident, processor outage or connector change goes into a log, since these can distort the comparison. At the end of the planned period, the team calculates the primary metric with the pre-agreed method and tests significance using a method chosen before launch, confirmed with an analyst. The check is that both arms received traffic in the expected proportion and that retries and fallbacks are attributed to the arm that started the payment.
Promote the winner only after review
The team compares the result with the original hypothesis and the guardrail record. If the variant improves the primary metric without breaching a guardrail, it is promoted through the same change process used for production routing, and the control version is kept for rollback. If results are inconclusive or a guardrail was breached, the team keeps control and records the finding. The check is that the promoted configuration matches the tested export and that the rollback version has been restored in staging.
Control and variant traffic meets the routing layer only after arm assignment
The diagram starts with an incoming payment request in your merchant backend, where each request is assigned to the control or variant arm and tagged with an arm label. The labelled request then passes the trust boundary into your self-hosted Hyperswitch services, where the control and variant routing configurations each send traffic to processors. Declines that trigger retries or fallback stay on the arm that handled the original payment, so the results still count toward that arm. Each outcome lands in an arm-level metrics store that compares approval rates. Confirm where assignment happens in your setup, because it must run before the request reaches Hyperswitch and the label must be stored with the payment record.
Arm assignment happens before Hyperswitch routing, and results feed a per-arm comparison.
Guardrails on approval rates that stop an A/B testing split
A routing variant can win on the metric you chose and still damage the business elsewhere. These guardrails watch the side effects of a split, so a test that hurts approvals, costs, or fallback behavior stops before it scales. Agree every threshold and stop action in writing before the first payment is routed.
Approval rate by network and country
Compare approval rate per arm for each major card network and each country you transact in, not only in aggregate. A variant can lift blended approvals while losing ground on one network or market that carries most of your revenue. Trip the guardrail when a segment drops below the floor set from your own pre-test baseline. Stop by reverting the arm assignment for the affected segment so the control arm receives that traffic again.
Decline rate by decline code group
Group processor decline codes into families such as issuer declines, insufficient funds, fraud suspicion and technical errors, then compare the mix per arm. A variant can keep the headline rate flat while shifting declines into a group that signals a configuration problem, such as a connector receiving traffic it handles poorly. Set the group limits with your payments and risk leads before the test starts. Stop by reverting the routing configuration that the variant uses.
Chargeback and dispute rate by arm
Disputes arrive weeks after the payment, so this guardrail reads slowly and needs data that is available for both arms. Ask your dispute team whether dispute data can be tied to the routing decision for each payment before you rely on it. A variant that routes more transactions to a processor with weaker fraud screening may raise disputes even when approvals rise. Because the signal lags, decide in advance whether the test can end before this guardrail has matured.
Processor error and timeout rates
Track errors and timeouts reported by each processor per arm, separately from declines, since a timeout is not a decline and the two have different causes. Spikes often come from a processor that is slow under the traffic share the variant sends it, which can also appear as duplicate-attempt risk. Set the threshold with your platform team and the processor's own status information. Stop by reverting the arm assignment and confirming the processor recovers before any retry of the test.
Latency added by routing decisions
Measure the time the routing decision adds to each payment, per arm, at the same percentiles you use for your checkout service. A variant that calls an extra decision step or a self-deployed routing service can slow checkout enough to reduce conversion before any approval change appears. Agree the latency ceiling with the team that owns checkout latency. Stop by reverting the routing configuration and checking that the decision service is healthy under the traffic it was receiving.
Share of traffic reaching fallback
Watch how often payments fall through to default fallback routing in each arm, because fallback is the path taken when no rule applies or the chosen processor is ineligible. A rising fallback share means the variant is sending payments to processors that cannot take them, and your results then reflect the fallback order, not the strategy under test. Set the ceiling from your baseline and confirm the fallback order is configured before the test begins. Stop by reverting to the control configuration and reviewing eligibility rules.
Hyperswitch routing docsReading A/B testing results by audience
Engineering owns the question of whether the experiment itself is valid. Before anyone reads an approval rate, the team confirms that each payment was assigned to the arm the plan intended, that the variant routing configuration was applied as written, and that the observed traffic split is close to the planned split. A result from a test that quietly leaked traffic or ran the wrong rules is not evidence about the strategy.
- Arm assignment: Sample payments and confirm each one carries the arm label it should. Check that the same customer or card is not flipping between arms in ways your design does not allow.
- Applied configuration: Compare the routing rules recorded for the variant against the approved change, including processor order, weights and fallback settings.
- Split accuracy: Compare observed volume per arm with the planned percentage, by hour and by payment method. A persistent gap points to a filter or retry path that bypasses the split.
- Change log: Record every configuration change made during the test window so a later reader can separate effects of the routing change from effects of unrelated deployments.
- Data completeness: Confirm that attempts, retries and webhook outcomes are all logged for both arms.
Engineering signs off only when the split and configuration match the written plan. Confirm the exact arm labels and logging fields with your Hyperswitch version and routing configuration before the test starts.
Payments operations reads what the routing change does to the flow of payments. The team compares approval rate, decline mix and fallback use between control and variant, and looks at whether the variant moved declines into a different category rather than removing them. A higher approval rate on one processor can hide a rise in a decline reason that customers or support teams will feel.
- Approval rate by arm: Compare authorization success for the same segments on both arms, such as card brand, region and ticket size, so a shift in mix does not look like a routing gain.
- Decline mix: Break declines into issuer, processor and fraud reasons for each arm. Check whether the variant reduces soft declines or only relabels them.
- Fallback use: Measure how often payments reach the default fallback routing on each arm. Heavy fallback use on the variant means the primary strategy is often ineligible, which is an operational risk even when the approval rate looks good.
- Retry behavior: Check retry counts and final outcomes per arm, since retries can inflate approvals and add load on processors.
- Processor health: Watch for error spikes or latency changes from a single processor during the test window.
Payments operations signs off when the approval gain holds across the main segments, the decline mix does not worsen for any segment, and fallback use is within the limits the team agreed before the test.
Risk and finance ask whether the routing change is good for the business after losses and costs are counted. An approval gain can be offset by more disputes, higher processor fees or chargebacks that arrive weeks later, so this audience needs a longer observation window than the test itself. Fee data and dispute outcomes often arrive after the test ends, so the sign-off plan should say which reports will be used and when.
- Dispute rates: Compare chargeback and dispute rates by arm, using the dispute window that applies to each card network. Early results are incomplete, so flag which cohorts are still open.
- Processor fees: Where settlement or invoice data is available for both arms, compare per-transaction cost. Confirm the cost data source and its coverage before using it in the decision.
- Net revenue effect: Estimate the change in captured revenue after refunds, disputes and fees for each arm, not only the change in approved volume.
- Fraud and loss exposure: Check whether the variant routes more traffic to processors with weaker fraud controls or different liability terms.
- Reporting cut-off: Agree in writing which dates and data sources the final decision uses.
Risk and finance sign off when net revenue and dispute exposure are acceptable on the agreed data, and when the cost figures come from a source they can verify. Ask your processors and finance team to confirm the reporting lags before the test begins.
Why significance alone does not approve a routing change
A statistically significant result tells you a difference is unlikely to be chance, and nothing more. Significance is an estimate of whether the gap in approval rate between control and variant would be surprising if the two routing strategies performed the same. It does not tell you that the gap is large enough to pay back the effort of changing routing, that the variant is safe for every card type, issuer and market, or that the sample reflects a normal business cycle. A payments leader who approves a rollout on the p-value alone has answered only the first of those questions. Before the split starts, agree with your data or analytics team the primary metric, the minimum approval-rate difference that would justify a change, the guardrail metrics, and the analysis method, including whether results are read at a fixed end date or monitored continuously. Write these down so the decision cannot drift once numbers appear.
Payments data is uneven in ways that make a short test misleading. Card mix shifts between credit and debit, domestic and cross-border, and co-badged networks. Issuer behavior varies by time of day, payday cycles and fraud rules that tighten or loosen without notice. Seasonality and promotions move volume and decline reasons at the same time. A test that runs for a few quiet days may capture one side of these patterns and miss the peaks where a processor's authorization behavior matters most. Run the split long enough to include the predictable peaks your business has, such as month-end, paydays, seasonal sales or known campaign windows, and confirm with your processor and merchant operations team which periods the split must cover. The Hyperswitch routing docs at Hyperswitch intelligent routing describe the strategies you will be comparing, so confirm which one your variant uses before you select the test window.
Slicing results by card network, issuer country, ticket size and hour produces many comparisons, and some of them will look like wins by chance alone. If you test twenty segments at a conventional threshold, one may appear significant even when the routing change has no effect. Decide the segments that matter before the test starts, keep that list short, and adjust the threshold or treat additional segment results as exploratory. Any segment that looks strong should be confirmed in a follow-up split before it drives a rollout decision. This applies equally to the variant's gains and to any drop in approval rate on a minority segment, which the guardrail review should catch.
What to confirm in your environment before the first split
A split only proves something if the routing version, the assignment record and the reporting all hold up under real traffic. The cards below list the items to verify with your own Hyperswitch deployment and processor contracts before any live traffic is divided between arms.
Version and routing configuration support
Confirm that your deployed Hyperswitch router, Control Center and client SDK versions support the split method you chose, and that the routing strategy you plan to test is available in your configuration. Check version alignment against the compatibility matrix published with each release on the releases page before scheduling the change. A split built on a feature your version does not expose will look like a test but will not measure what you intended.
Releases and compatibility matrixArm assignment storage and persistence
Ask where each payment's arm assignment is recorded and whether that record survives retries, 3DS step-ups and asynchronous webhook updates. If a retry can land on a different arm, control and variant results will be mixed and the comparison will be invalid. Decide whether assignment is keyed to the customer, the payment intent or the attempt, and confirm that the choice matches how your team reads outcomes.
Processor-side limits and volume commitments
Check whether any processor contract sets minimum volumes, committed shares or throughput caps that a percentage split could breach. A variant arm that starves a committed processor can trigger shortfall terms, while an arm that concentrates volume may hit a limit and distort approval rates. Ask each acquirer which limits apply during a test window and record them before the split opens.
Control Center reporting by configuration
Confirm that the Control Center can separate results by routing configuration, not only by processor, so each arm can be read on its own. Test this with a small dummy split in a sandbox before relying on it. If the dashboard only shows aggregate figures, plan an export of transaction-level records to compute the arm comparison yourself.
Transaction-level data retention
Establish how long transaction-level records, attempt history and routing decision data are kept in your deployment, and whether that period covers the full analysis window plus the time needed for dispute and chargeback follow-up. Confirm who can export this data and where it is stored. Retention shorter than your test length means results cannot be recalculated later, and any personal data kept for analysis must fit your privacy obligations.
Release and upgrade window requirements
Determine whether changing routing rules in your environment requires a configuration change only or a release, redeploy or upgrade window. Some Hyperswitch upgrades carry required dependencies, so check the release notes for any change that must land first. Agree a change freeze with your platform team for the test period, and define in advance who can stop the split if approval rates fall outside the guardrails.
A/B testing routing questions buyers ask
How much more effort is an A/B routing test than a direct change?
An A/B test adds work before and after the change, but it does not require a different routing engine. A direct change edits one routing strategy and watches the dashboard. A split keeps two configurations live at once, assigns each payment to an arm, records which arm handled it, and compares outcomes at the end. The extra effort grows with the number of arms, the processors involved, the markets in scope and the depth of analysis. Confirm how arms are configured in your Hyperswitch version using the Hyperswitch intelligent routing docs before estimating the build.
How long should a routing A/B test run?
A split should run until it has enough payments to separate the arms from normal variation. That depends on your traffic volume, the approval rate you measure and the size of the difference you need to detect. No duration is supplied for Hyperswitch, so do not plan from a fixed number of days. Low-volume markets, card types or processors can take much longer to reach a usable sample. Calculate the required sample size before launch, and keep the test running through a full business cycle so weekday, weekend and month-end issuer patterns all appear in both arms. Write the stopping conditions down before the first payment is routed.
What does an A/B test need from our internal team?
Your team needs four things: an owner for routing configuration in the Control Center, an engineer who confirms that every payment records its arm, an analyst who can join routing decisions to final outcomes, and a named approver for the rollout decision. Finance should validate processor cost data if cost is part of the test. Security should review who can read transaction-level data used for analysis. Someone must also watch guardrails during the split. Plan for SQL skills, basic statistics and access to the Hyperswitch admin interfaces, because most delays come from missing data rather than from the routing change itself.
Can our team run routing tests without an outside partner?
Yes, if your team has configuration access, a reliable transaction data pipeline and someone who can design and read the test. Hyperswitch is open source under Apache 2.0, so you can self-host it and change routing settings yourself. The harder parts are usually data work: matching each routing decision to its final result, handling retries so they are not counted twice, and avoiding bias from uneven traffic. A partner is useful when the pipeline needs building, when you want an independent review of the test design before rollout, or when you need someone to present the result to a risk committee. Ask your team to explain how it will avoid bias before deciding.
What drives the cost of outside help with routing tests?
The main cost drivers are the number of arms, the number of markets and processors in scope, the amount of data pipeline work and the depth of analysis you ask for. A two-arm test on one processor with existing reporting is much smaller than a multi-market test that needs new event logging and a formal statistical review. DeployOpen does not publish prices. Engagements are fixed scope, with deliverables and timelines agreed in writing before work starts, and ongoing testing is available as a retainer. Ask any provider for the scope of each arm and market, which data sources they will touch, what is one-time work such as pipeline setup, what recurs such as monthly reviews, and what the quote excludes.
How do we stop an A/B test if guardrails are breached?
Stop the test by setting the variant's share of traffic to zero in the routing configuration, which sends payments back to the control arm, then confirm that new payments are routing as expected. Guardrails should be defined before launch, with thresholds on approval rates for each processor and market, plus alerts for sudden decline spikes, since averages can hide a problem in one segment. Assign one person the authority to stop the test and a backup for out-of-hours. Investigate the cause before any restart. Confirm in your Hyperswitch version how quickly a configuration change takes effect, so the stop time is written into the runbook.
What happens to payments mid-retry when a routing split ends?
Confirm the exact behavior in the Hyperswitch docs for your version before relying on it, because a payment already in progress may be tied to the arm that started it. Plan for both cases. Before ending a split, stop sending new traffic to the variant, allow in-flight payments and retries to complete, and record which arm each attempt used, so analysis counts attempts correctly and does not credit a retry to the wrong arm. Check that no payment is left in a pending state after the change, and reconcile the final counts against processor reports. Document the cutover time so finance and support can match disputes and refunds to the correct routing decision.
How DeployOpen scopes and delivers routing experiments
DeployOpen plans, implements and documents self-hosted open-source platforms inside your own infrastructure, including Hyperswitch routing changes. For A/B testing, we treat each routing variant as a controlled change with a written scope, a measured control arm, guardrails agreed up front and a handover your team can run without us.
How we scope
- Agree in writing which routing strategy is the control and which is the variant, and why the test is worth running
- Confirm the processors, merchants, payment methods and traffic share that will enter each arm before any split is configured
- Define approval-rate guardrails, the metrics read-out and the decision rule for rollout, pause or rollback
- Engagements are fixed-scope, with deliverables and timelines written down before work starts; ongoing support is available as a retainer
How we build
- Configure the control and variant arms in your self-hosted Hyperswitch environment and verify the split matches the written design
- Check the routing service, fallback routing and decline handling so both arms fail in predictable ways during the test
- Set up dashboards and queries that report approval rates, volume and processor mix per arm from your own data
- Test the configuration in a non-production environment before any live traffic is directed to the variant
How we hand over
- Document the hypothesis, arm definitions, guardrails, sample period and the statistical method used to read results
- Deliver a results runbook that shows how to pause a split, roll back a variant and record the decision
- Walk your payments and risk teams through the readout so they can interpret the numbers without DeployOpen present
- Provide change records that your compliance and audit teams can review alongside the routing configuration
How we support
- Repeat the experiment process for later changes, such as a new processor or a revised multi-objective weighting, under the same written scope
- Keep the Hyperswitch version, Control Center and routing settings current as part of an ongoing retainer when you want that
- Confirm with your own team how long each test must run, since that depends on your volumes and the effect size you need to detect
- Re-check guardrails after upgrades, because routing behavior and dashboards can change between Hyperswitch releases

