UnionPay Test Number Generator
Generate Luhn-valid UnionPay test numbers (16/17/18/19 digits) for form and validation testing.
Tool inputs stay in your browser · optional AI search sends your query
Good to know: Numbers start with the network’s public prefix and end with a correct Luhn check digit, so they pass format validation in your own forms. For software testing only. These are not real cards: they are not linked to any bank account and cannot be used to pay for anything. For real payment-gateway tests, use the official test cards for your provider (see Test Credit Card Numbers).
How to use it (step by step)
- 1Choose your options: “Brand”, “How many”, “Output”, “Length”.
- 2Press “Generate test numbers”.
- 3Copy the result with the Copy button. Press the button again for a fresh result.
Words to know
- Luhn check
- A quick math test every real card number passes, like a spelling check for numbers. Passing it only means the number is typed in the right shape, not that the card is real.
- Test / sandbox mode
- A practice version of a payment system. You can “pay” with test cards to try your checkout, but no real money moves.
- Public vs private IP
- Your router gives each device a private IP (like 192.168.1.5) at home. The internet only sees one public IP for your whole house.
More in Cards & Payments
Credit Card Payment BreakdownHow much of your payment goes to interest vs balance this month, and your new balance.Credit Card Payoff Goal CalculatorThe monthly payment needed to be debt-free in the number of months you choose.Card Processing Fee CalculatorFee and net amount for a card payment with a percentage + fixed fee (and tax on fees).Fee Gross-Up Calculator (Charge to Receive)How much to charge so you receive an exact amount after card fees.Card Surcharge CalculatorAdd a card surcharge to a price, or find the surcharge that exactly covers your fee.Merchant Discount Rate (MDR) CalculatorMonthly MDR cost, tax on MDR and net settlement from your card sales.