Validation Summary
{{ summary.main.is_valid ? 'Valid' : 'Invalid' }}
{{ summary.supplementary.valid + (summary.main.is_valid ? 1 : 0) }} Valid {{ summary.supplementary.invalid + (summary.main.is_valid ? 0 : 1) }} Invalid
Credit-card numbers
Entries: {{ results.length }}
# Number Valid Type MII IIN-6 IIN-8 Len Length OK Copy
{{ i + 1 }} {{ maskNumbers ? mask(r.number) : spaced(r.number, r.card_type) }} {{ r.is_valid ? 'Yes' : 'No' }} {{ r.card_type }} {{ r.mii }} {{ r.iin }} {{ r.iin8 }} {{ r.length }} {{ r.length_valid ? 'Yes' : 'No' }}
No results yet.
Number{{ maskNumbers ? mask(summary.main.number) : spaced(summary.main.number, summary.main.card_type) }}
Type{{ summary.main.card_type }}
Length{{ summary.main.length }}
Expected Lengths{{ (summary.main.expected_lengths && summary.main.expected_lengths.length ? summary.main.expected_lengths.join(', ') : '—') }}
MII{{ summary.main.mii }}
IIN-6{{ summary.main.iin }}
IIN-8{{ summary.main.iin8 }}
Luhn Valid{{ summary.main.is_valid ? 'Yes' : 'No' }}
Length OK{{ summary.main.length_valid ? 'Yes' : 'No' }}
No details yet.

            

Introduction:

Credit card numbers are structured identifiers that encode basic issuer information and finish with a check digit that guards against common entry errors. Understanding this structure helps you tell a simple typo from a number that fits known patterns, and a credit card number checker can surface those differences quickly.

Enter one or many numbers and see immediate feedback about overall validity, issuer family, and length expectations so you can clean a list before it flows into another system. Results highlight which entries pass the checksum and which ones do not, with optional masking when you only need to confirm endings.

For example, a list collected from a webform might include spaces and punctuation, so paste it in and review the counts by issuer and by length. If a number looks plausible yet still fails, it usually means a transposed pair of digits or an extra character slipped in during capture.

Use consistent formatting and compare like with like for clearer trends. Prefer test data in shared environments, and avoid storing or forwarding real customer numbers when a masked sample is sufficient. When you need an issuer snapshot, switch to the stats view after validation and scan the distribution.

Technical Details

Credit card numbers belong to a family of structured identifiers that begin with a Major Industry Identifier (MII), include an Issuer Identification Number (IIN, sometimes called BIN), carry an account sequence, and end with a check digit computed by the Luhn method. The analysis here is a snapshot of those quantities for each submitted token.

The computation first strips non‑digits, then evaluates the Luhn checksum to detect common single‑digit errors and adjacent transpositions. It separately recognizes issuer families from prefixes and compares the observed length to scheme‑typical ranges. These pieces are reported per number as independent indicators.

Results are interpreted as two flags: overall Luhn valid or not, and length OK when strict length checking is enabled. Close calls are common near length edges, so treat a Luhn pass with an unexpected length as suspicious rather than definitive.

Comparisons are meaningful across runs when inputs are captured in the same way and duplicate handling is consistent. Pattern recognition does not verify an account or line of credit; it only checks structure and checksum behavior.

Digits = (d1, d2, , dn) ti = dni+1 vi = { tiif i is odd 2ti9if i is even and doubling exceeds nine 2tiif i is even and doubling stays at most nine } S = i=1 n vi Luhn valid Smod10=0
Symbols and units
Symbol Meaning Unit/Datatype Source
diDigit at position i from the left0–9Input
tiDigit i after reversing order0–9Derived
viTransformed digit after doubling logic0–9Derived
SSum of transformed digitsIntegerDerived
nNumber of digitsIntegerInput

Worked example. Input “4111111111111111” (spaces or punctuation are ignored). After reversing and applying the doubling rule, the transformed sequence sums to S = 30. Since 30 mod 10 equals 0, the checksum passes. Prefix “4” suggests Visa, and a length of 16 matches typical Visa lengths.

S=30valid

If strict length checking is enabled and the length falls outside a scheme’s allowed set, the Length OK flag will show “No” even when the checksum passes.

Issuer families and expected lengths
Issuer family Prefix recognition (summary) Expected lengths
VisaStarts with 4; length recognition uses 13 to 1913, 16, 19
MasterCard51–55 or 2221–272016
American Express34 or 3715
Diner’s Club300–305 or 36 or 3814
Discover6011 or 65 or 644–649 or 622126–62292516–19
JCB2131 or 1800 or 3516–19
UnknownPattern not matched
Major Industry Identifier mapping
MII digit Meaning
0ISO/TC 68
1Airlines
2Airlines/Finance
3Travel/Entertainment
4Banking
5Banking
6Merchandising
7Petroleum
8Healthcare/Telecom
9National assignment
  • Non‑digits are stripped per token before validation.
  • IIN‑6 and IIN‑8 are reported as the first 6 and first 8 digits.
  • Display formatting groups digits in fours except American Express (4‑6‑5) and Diner’s Club (4‑6‑4).
Validation and input bounds
Field Type Min Max Step/Pattern Error text Placeholder
Numbers Textarea Split on spaces, commas, new lines; strip non‑digits Paste numbers or drop a .txt/.csv
Strict length check Boolean 0 1 Switch
Remove duplicates Boolean 0 1 Switch
Minimum digits per token Number 0 Step 1
Import list File Accepts .txt, .csv
I/O formats
Input Accepted families Output Encoding/Precision Rounding
Text or file Plain text, .txt, .csv List view String digits only None
Text or file Plain text, .txt, .csv Stats Counts by validity, issuer, length None
Text or file Plain text, .txt, .csv JSON or CSV JSON with inputs/totals/results; CSV rows with columns shown None

Units, precision, and rounding. Inputs are base‑10 digits; non‑digits are removed. No rounding is applied. Computation is integer‑safe for typical card lengths.

Networking and storage behavior. Processing occurs in the client. Charts may rely on a charting layer that is fetched from a public source; if it is unavailable, validation still runs but charts may not render.

Performance and complexity. Parsing and validation are linear in the number of digits; memory use scales with the number of tokens.

Diagnostics and determinism. Identical inputs and settings produce identical outputs. JSON export reflects the exact flags shown in the list view.

Security considerations. Treat credit card numbers as sensitive. Prefer masked displays when possible, avoid sharing raw values, and rely on recognized test numbers for demonstrations.

Assumptions & limitations

  • Checksum pass does not prove an active account.
  • Prefix recognition is pattern‑based and may change as issuers evolve.
  • Length checking is optional; defaults do not enforce scheme lengths.
  • Duplicate removal alters counts; disable when auditing raw capture.
  • Whitespace and punctuation are ignored; other symbols are stripped.
  • IIN reporting is informational; it is not a database lookup.
  • Very long tokens will be processed but are unlikely to match a scheme.
  • Heads‑up Charts require the charting layer; without it, stats are unavailable.

Edge cases & error sources

  • Non‑ASCII numerals; only 0–9 are parsed.
  • Leading zeros; kept and considered in length.
  • Invisible control characters; stripped during parsing.
  • Mixed separators; tokens split by any whitespace or comma.
  • Adjacent transpositions; detected by Luhn only in many, not all, cases.
  • Copy‑paste artifacts; soft hyphens or narrow spaces.
  • Right‑to‑left marks; may affect visual grouping only.
  • Extremely short tokens; optionally dropped via minimum‑digits filter.
  • Malformed files; only plain text and CSV are accepted for import.
  • Stale cached scripts; charts may fail until the cache refreshes.

Privacy & compliance. No data is transmitted or stored server‑side. Use masked displays and test data where policy requires.

Step‑by‑Step Guide

Credit card number validation with checksum and issuer recognition.

  1. Paste numbers or import a .txt or .csv list.
  2. Optionally enable Strict length check for scheme‑typical lengths.
  3. Toggle Remove duplicates to drop repeated tokens.
  4. Set Minimum digits to discard short noise.
  5. Run validation and review the list; switch to stats for distributions.
  6. Copy or download JSON/CSV when you need to share structured results.

Example. Paste “4111 1111 1111 1111, 6011‑0000‑0000‑0004” and enable strict lengths to see a Visa pass and a Discover‑pattern result evaluated by checksum.

Pro tip: mask numbers when presenting findings to keep focus on patterns, not raw values.

You now have a clean list with clear pass/fail signals and issuer context.

FAQ

Is my data stored?

No. Processing is client‑only. A charting layer may be fetched for the stats view; validation still runs without it.

Avoid sharing real customer numbers; prefer masked or test values.
How accurate is the check?

It applies the Luhn checksum and prefix recognition. These detect common errors and issuer families but do not confirm that an account exists or can transact.

What inputs are supported?

Paste plain text with numbers separated by spaces, commas, or lines, or import .txt or .csv files. Non‑digits are removed per token before validation.

Can I use it offline?

Yes for validation and lists. The stats view needs a charting layer; if it is unavailable, charts will not render.

What does “borderline” mean?

A number can pass the checksum while its length differs from scheme‑typical ranges. Enable strict length to surface a Length OK flag for those cases.

How do I check a Visa number?

Paste the number, run validation, and confirm a prefix of 4 with a length of 13, 16, or 19 alongside a passing checksum.

Can I export the results?

Yes. Copy or download CSV for the table and JSON for the structured payload containing inputs, totals, and per‑number results.

What about licensing or cost?

The package does not declare licensing terms here. Consult the host site’s terms for usage and redistribution details.

Troubleshooting

  • Validate button disabled: add at least one digit to the input.
  • No results after file import: only .txt and .csv are accepted.
  • All entries show “Unknown”: ensure digits remain after stripping punctuation.
  • Masked display hides digits: turn off masking to inspect full values.
  • Charts do not appear: open the stats tab after validation and ensure the charting layer is available.
  • CSV opens in one line: use a spreadsheet app’s CSV import rather than a plain editor.

Advanced Tips

Tip Use minimum‑digits filtering to remove short IDs that are not card numbers.

Tip Disable duplicate removal while auditing sources, then enable it for final lists.

Tip Compare issuer distributions before and after cleaning to spot capture biases.

Tip Keep masking on when screen‑sharing; reveal only the digits you need to show.

Tip Export JSON for reproducible pipelines; it records options, totals, and results.

Tip Enforce strict length before sending a list to any downstream system.

Glossary

Major Industry Identifier (MII)
First digit indicating the broad industry category.
Issuer Identification Number (IIN/BIN)
First 6 or 8 digits identifying the issuing institution.
Luhn checksum
Mod‑10 check that detects common digit errors.
Check digit
Final digit chosen to satisfy the checksum.
Length OK
Flag indicating that observed length matches scheme expectations.
Masking
Display choice that hides all but the last four digits.