DevTools Logo

Swiss UID Generator

Swiss UID Generator

Generate Swiss enterprise identification numbers (CHE-xxx.xxx.xxx) with the mod-11 check digit — synthetic test data only

Runs in your browser

For Development & Testing Purposes Only - Synthetic Mock Data

Settings

1 value

Generates one value with a valid checksum. Press ⌘/Ctrl+Enter for a fresh one.

Generated value

No value yet

Set options, then press Generate.

Generated values are valid in shape but randomized (Test Data).

Legal Disclaimer: Generated data is for software testing and validation purposes only (e.g. verifying input masks, form validation, or database seeding). It is randomly generated and not taken from any real record, but a random value can coincidentally match a real, issued number, so never use it in real applications, payments, KYC or official forms. Using it to impersonate real people or for any fraudulent activity is illegal. DevTools accepts no liability for how generated data is used.

    Examples

    Generate a UID

    Input
    UID · Generate
    Output
    CHE-116.281.710

    The first eight digits sum to 132, and 132 mod 11 is 0, so the check digit becomes 0.

    Validate a VAT-registered UID

    Input
    CHE-116.281.710 MWST
    Output
    Valid — the MWST suffix is ignored

    The validator strips MWST before recomputing the check digit.

    Reject a wrong check digit

    Input
    CHE-116.281.711
    Output
    Invalid — check digit is 1 but the first 8 digits require 0

    A single changed final digit fails the mod-11 check.

    About this tool

    The Swiss UID Generator produces one enterprise identification number in the CHE-xxx.xxx.xxx format. The nine digits after CHE end in a check digit computed from weights 5, 4, 3, 2, 7, 6, 5 and 4 modulo 11; a result of 11 becomes 0, and 10 is never issued.

    VAT-registered businesses append MWST, TVA or IVA to the same UID, and the validator strips that suffix along with spaces and dots. Generation retries when the first eight digits produce the unused value 10, so every result is a valid UID.

    These are synthetic values for QA and development, never for real applications, KYC checks, tax filings, identity documents or impersonation. A random value can coincide with a real, issued number, and DevTools accepts no liability for how generated data is used. Everything runs locally in your browser.

    What this tool does not do

    • Generates the UID only; AHV numbers live in a separate tool.
    • Validation confirms the checksum, not that the company is registered.
    • A random value can match a real company's UID.
    • The VAT suffix is accepted but not validated against a VAT register.

    How to use this tool

    1. Choose the UID option

      The tool is pinned to the Swiss UID, which uses CHE plus nine digits and a mod-11 check digit.

    2. Generate a value

      Click Generate to create one CHE-xxx.xxx.xxx value whose final digit passes the check.

    3. Validate or copy

      Switch to Validate to check a pasted value with or without a VAT suffix, or copy the result as a .txt file.

    Use cases

    Supplier onboarding fixtures

    Seed Swiss supplier records with a CHE UID that passes the mod-11 check instead of a real company identifier.

    VAT field tests

    Exercise VAT-registered input paths by appending MWST, TVA or IVA to a generated UID.

    Suffix-handling tests

    Confirm that your parser accepts a UID with and without the VAT suffix.

    Swiss UID rules

    PartRule
    FormatCHE-xxx.xxx.xxx
    Weights5, 4, 3, 2, 7, 6, 5, 4 over the first 8 digits
    Check digit11 − (sum mod 11); 11 becomes 0, 10 is never issued
    VAT suffixMWST, TVA or IVA for VAT-registered businesses
    ValidationIgnores CHE, spaces, dots and the VAT suffix

    A check-digit value of 0 is valid; it comes from a raw result of 11.

    Common mistakes

    Mistake:Treating MWST as part of the number

    Fix:The suffix marks VAT registration; it is not part of the UID checksum.

    Mistake:Expecting check value 10 to be valid

    Fix:10 is never issued, so the generator retries and the validator rejects such a value.

    Mistake:Rejecting a check digit of 0

    Fix:A raw result of 11 becomes 0, so a final zero is a valid check digit.

    Frequently asked questions

    Are these real Swiss UID numbers?

    No. They are synthetic values for QA and development and cannot be used for real registrations, VAT filings, invoices, KYC checks, or identity documents; DevTools accepts no liability for how they are used.

    What do the MWST, TVA and IVA suffixes mean?

    They mark a VAT-registered business in German, French and Italian. The validator strips the suffix before the checksum, so the same UID is valid with or without it.

    Why can a Swiss UID end in 0?

    The check digit is 11 minus the weighted sum modulo 11. A raw result of 11 becomes 0, so a trailing zero is a legitimate check digit, while a raw result of 10 is never issued.

    Can a generated UID match a real company?

    It can. The mod-11 check only shows the number is well formed, so a random value may coincide with a registered company. Use generated values in test environments only.

    Is CHE part of the number?

    Yes. CHE is the fixed prefix of every Swiss UID; the nine digits after it carry the identifier and the final check digit. Spaces and dots are ignored during validation.

    References & standards