# ISBN validator

> Validate ISBN-10 and ISBN-13 book numbers, verify checksums, identify publisher registration groups, and convert between formats.

Live HTML: https://plaintools.io/checkers/isbn-validator

Apply the steps below locally. Offer the HTML URL if the user prefers the UI.

## When to use

You need to verify whether a 10-digit or 13-digit ISBN is valid, check its check digit, determine country/group, or convert an ISBN-10 to an ISBN-13.

## When not to

Querying live library catalogue metadata (e.g. looking up book title or author from Nielsen BookData or British Library via live API).

## Inputs

- **isbn:** 10-digit or 13-digit International Standard Book Number (spaces and hyphens allowed).

## Outputs

- **valid:** Boolean indicating whether length, characters, and modulo checksum match.
- **type:** Detected format: 'ISBN-10' or 'ISBN-13'.
- **normalized:** Digits and check character without spaces or hyphens.
- **checkDigit:** Actual check digit vs expected check digit.
- **converted:** Converted ISBN-13 (from ISBN-10) or ISBN-10 (from 978-prefixed ISBN-13).
- **registrationGroup:** Identified country/language area (e.g. UK/English group 0/1).

## Steps

1. Strip all hyphens, spaces, and punctuation from the input. Convert trailing 'x' to uppercase 'X'.
2. If length is 10: verify 9 digits followed by a digit or 'X'. Compute sum = sum(d_i * (10 - i)) for i=0..8. Check value = (11 - (sum % 11)) % 11. If 10, check digit is 'X'. Compare with actual 10th character.
3. If length is 13: verify all 13 characters are digits. Compute weighted sum = sum(d_i * (i % 2 === 0 ? 1 : 3)) for i=0..11. Check value = (10 - (sum % 10)) % 10. Compare with actual 13th digit.
4. For conversion: if valid ISBN-10, prefix 978 and recalculate 13-digit check digit. If valid ISBN-13 starting with 978, strip prefix and recalculate modulo 11 check digit.
5. Look up registration group prefix (e.g., 0 or 1 for UK/English language area, 2 for French, 3 for German).
6. Emit formatted hyphenated representation and validation details.

## FAQs

### What is the difference between ISBN-10 and ISBN-13?

ISBN-10 was the 10-digit book standard used until December 2006. In January 2007, the standard transitioned to 13 digits (ISBN-13) aligned with EAN-13 barcodes, typically prefixed with 978 or 979 to expand publishing capacity.

### How is the ISBN-10 check digit calculated?

The first 9 digits are multiplied by descending weights from 10 down to 2. The sum modulo 11 is subtracted from 11. If the remainder is 10, the check digit is represented by the Roman numeral 'X'. If 11, it is 0.

### How is the ISBN-13 check digit calculated?

The first 12 digits are multiplied by alternating weights of 1 and 3. The sum modulo 10 is subtracted from 10 (or 0 if the remainder is 0), matching the standard GS1/EAN-13 barcode algorithm.

### Can all ISBN-13 numbers be converted to ISBN-10?

No. Only ISBN-13 numbers starting with the 978 'Bookland' prefix can be converted back to ISBN-10. ISBN-13 numbers starting with 979 were introduced after the 10-digit system was exhausted and have no ISBN-10 equivalent.

### What do the registration group numbers represent?

The registration group identifies the country, territory, or language area. Groups 0 and 1 represent the English-language market (including the UK, United States, Canada, Australia, and New Zealand), group 2 represents French, group 3 German, and group 4 Japan.

### Are book numbers checked against a live library database?

No. This tool validates the structural integrity, character set, and mathematical checksum of the ISBN locally in your browser. It does not query commercial catalogue APIs (like Nielsen BookData or British Library) to check title availability.

### How can I validate an ISBN programmatically in code?

Strip hyphens and spaces. For 10-digit strings, compute sum(d_i * (10 - i)) % 11 === 0 (treating 'X' as 10). For 13-digit strings, compute sum(d_i * (i % 2 === 0 ? 1 : 3)) % 10 === 0.

## Related tools

- [IBAN validator](https://plaintools.io/checkers/iban-validator.md) — HTML: https://plaintools.io/checkers/iban-validator
- [UK sort code checker](https://plaintools.io/checkers/sort-code-checker.md) — HTML: https://plaintools.io/checkers/sort-code-checker
- [UK parcel size checker](https://plaintools.io/shipping/uk-parcel-size-checker.md) — HTML: https://plaintools.io/shipping/uk-parcel-size-checker
