Visa Expired Card Test Card Numbers
Visa · Expired Card: Expired cards should fail before authorization. MockCard simulates expired_card so expiry validators and gateway responses stay in sync.
Visa test PANs use standard 16-digit formatting. MockCard returns Luhn-valid numbers and a signed payment_intent webhook — ideal for Stripe-style integrations and CI pipelines.
When to use: Test client-side expiry checks, saved-card flows, and dunning when a stored instrument expires.
CI tip: Use distinct brands (Visa vs Amex) to catch length and CVV validation bugs.
Typical decline_code in webhook payloads: expired_card.
Click card to flip
Visa expired card test card example
Generated by the MockCard API on November 4, 2026. Every MockCard number is fictitious and Luhn-valid; the outcome comes from the scenario field, so any Visa number below returns expired_card when you send that scenario.
- Card number
- 4010 8522 7831 2776
- Expiry
- 02/29
- CVV
- 118
- Name
- JOHN DOE
Request
curl -X POST https://www.mockcard.io/api/v1/generate \
-H "Content-Type: application/json" \
-H "X-Api-Key: $MOCKCARD_API_KEY" \
-d '{"brand": "visa", "scenario": "expired_card"}'Response · HTTP 402
{
"error": {
"code": "expired_card",
"message": "The card has expired. Please use a valid expiry date.",
"next_action": null,
"decline_code": "expired_card"
}
}Webhook event: payment_intent.payment_failed
{
"id": "evt_mock_10e5479a82cc",
"data": {
"object": {
"id": "pi_mock_e11c10c0be06",
"amount": 1000,
"object": "payment_intent",
"status": "requires_payment_method",
"currency": "inr",
"next_action": null,
"last_payment_error": {
"code": "expired_card",
"type": "card_error",
"message": "The card has expired. Please use a valid expiry date.",
"decline_code": "expired_card"
},
"payment_method_details": null
}
},
"type": "payment_intent.payment_failed",
"object": "event",
"created": 1793782246,
"delivery": null,
"livemode": false
}Same scenario, other networks
Need webhook race conditions or 3DS abandonment? See payment failure testing and the API docs. Compare plans on pricing.
API example
const res = await fetch("https://mockcard.io/api/v1/generate", {
method: "POST",
headers: {
"Content-Type": "application/json",
"X-Api-Key": process.env.MOCKCARD_API_KEY ?? "",
},
body: JSON.stringify({
brand: "visa", // visa | mastercard | rupay | amex
scenario: "success", // success | insufficient_funds | 3ds_challenge …
}),
});
const card = await res.json();
// { card_number, expiry_month, expiry_year, cvv, brand, scenario }
console.log(card.card_number, card.cvv);