ForHosting KIT · Validation

Costa Rica ID number validator

Enter 1-0234-0567 and you learn it is a valid personal cédula, stored as 102340567 and shown in its usual hyphenated form. Company numbers, DIMEX and NITE are recognised too. Only the format is checked, not the registry. Free in your browser.

  • Free
  • Runs in your browser
  • No sign-up
  • Your data stays on your device
Use it from WebAPIEmailTelegramApp soon
If you enter
Identification number
1-0234-0567
You get
Kind of identification
Individual (cédula física)
Digits only
102340567
With hyphens
1-0234-0567

In Costa Rica every person and every company is identified by a number. Citizens carry a cédula de identidad, the national identity card; companies and associations have a cédula jurídica, their legal-entity number; foreign residents hold a DIMEX, the identity document issued to foreigners who live in the country; and people or entities that need a tax number without having any of these receive a NITE from Hacienda, the Costa Rican tax authority. This tool checks whether the number in front of you matches the format of one of them, tells you which one it is and gives it back in two versions: digits only, and written the way Costa Ricans usually write it. It is useful when you hire staff, onboard a supplier or issue an electronic invoice in Costa Rica, so a mistyped number does not travel any further. It checks the format, not the registry: a well-formed number does not prove that it exists or that it belongs to whoever gave it to you.

The four kinds of Costa Rican ID and how to tell them apart

The formats come from the Dirección General de Tributación, Costa Rica's tax administration, which publishes them in Anexos y Estructuras version 4.4, its technical document for electronic invoices, and the tool applies them as written. A personal cédula has 9 digits and never starts with zero; it is written in three groups, as in 1-0234-0567. A cédula jurídica has 10 characters: one digit for the type, three for the class and six for the sequential number, as in 3-101-123456.

A DIMEX has 11 or 12 digits, does not start with zero either, and is written as a single block without hyphens. A NITE also has 10 digits, like a cédula jurídica; the tool tells the two apart by the opening digits that only a NITE uses. You can paste the number however you have it, with hyphens, spaces or dots.

If a personal cédula comes with an extra zero in front, as some systems write it, the tool drops that zero and returns the usual 9 digits. If the number has been shortened by leaving out the padding zeros inside each group, it comes up short and fails, so complete it exactly as it appears on the card.

Reading the result: four real examples

Enter 1-0234-0567 and the answer is a valid format, a personal cédula, digits-only form 102340567 and hyphenated form 1-0234-0567. Enter 3-101-123456 and the format is that of a cédula jurídica, stored as 3101123456 without hyphens. Enter 155812345678, which has 12 digits, and the tool recognizes a DIMEX and leaves it as it is, because that document is not written with hyphens.

Enter 12-345 and the answer is not valid: its 5 characters do not match any Costa Rican identification. If you already know what you expect to receive, you can say so. When you ask a supplier for its cédula jurídica and the person types their own personal cédula instead, the format is fine but it is not what you asked for, and the tool flags it rather than accepting it.

Keeping the digits-only form means the same number is always stored the same way in your payroll, your invoicing software or your customer list, so a stray hyphen or space never makes two identical numbers look different.

What a valid format cannot tell you

None of these numbers carries a check digit; the official sources do not define one. That has a practical consequence worth knowing. If someone mistypes a digit or swaps two of them, the number keeps the right length and the format stays valid, so no format check can catch that mistake.

A valid result tells you the number is well formed. It does not tell you that the number exists, that it is current or that it belongs to the person or company that gave it to you. For that you need the body that issues it: the civil registry of the Tribunal Supremo de Elecciones, the Supreme Electoral Tribunal, for individuals; the Registro Nacional, the national registry, for legal entities; the Dirección General de Migración y Extranjería, the immigration office, for a DIMEX; and Hacienda for tax registrations.

When you hire someone or register a client, compare the number with the original document and keep the clean form the tool gives you.

An announced change to the cédula jurídica

The last six characters of a cédula jurídica, its sequential number, are due to become alphanumeric; an example of the new form is 3-101-A00001. The fourth quarter of 2026 has been mentioned as the target date, but we could not confirm it in an official source, so do not treat it as final. The tool already accepts a letter in that position, so a new legal-entity number will not be rejected by mistake.

If your invoicing or payroll software only allows digits in that part of the number, it is worth checking before the first ones appear. For anything unusual, such as a foreign document or an entity that fits none of these formats, the institution that issues the document, or your accountant in Costa Rica, has the final word.

Hiring a worker in Costa Rica

Before you add someone to the payroll you report to the CCSS, the Costa Rican social security fund, check that the cédula or DIMEX you wrote down has the right format. A missing digit is caught on the spot, not months later.

Issuing an electronic invoice

A Costa Rican electronic invoice asks for the kind and number of the customer's identification. The tool tells you whether it is a personal cédula, a cédula jurídica, a DIMEX or a NITE, and gives you the number without hyphens, ready to copy.

Onboarding a supplier

When a company signs up as a supplier, say that you expect a cédula jurídica. If someone enters a personal cédula by mistake, the tool points it out even though the format itself is correct.

Cleaning a customer or employee list

The same number written with hyphens, spaces or dots looks like several different entries in a spreadsheet. Converting every number to its digits-only form lets you spot duplicates and match records reliably.

How many digits does a Costa Rican cédula have?

Nine, and it never starts with zero. It is usually written in three groups separated by hyphens, as in 1-0234-0567, while the digits-only form is 102340567. If a system shows it with an extra zero in front, it is the same cédula: the tool removes that zero.

How many digits is a DIMEX number?

A DIMEX, the identity document for foreign residents of Costa Rica, has 11 or 12 digits and does not start with zero. It is written as one block without hyphens, for example 155812345678.

What does a Costa Rican cédula jurídica look like?

It has 10 characters: one digit for the type, three for the class and six for the sequential number, written with hyphens as in 3-101-123456. The sequential part is expected to admit letters, as in 3-101-A00001, and the tool already accepts that.

What is a NITE in Costa Rica?

It is a special tax identification number that Hacienda, the Costa Rican tax authority, assigns to people or entities that need one for tax purposes and have neither a cédula nor a DIMEX. It has 10 digits, and the tool tells it apart from a cédula jurídica by its opening digits.

Does the Costa Rican cédula have a check digit?

No. The official sources define no check digit for any of these numbers. That is why a wrong digit that does not change the length cannot be caught by a format check, so always compare the number with the document itself.

If the format is valid, does the cédula exist?

Not necessarily. A valid format only means the number is well formed. To know whether it exists and who it belongs to, you have to check with the Tribunal Supremo de Elecciones, the Registro Nacional, the immigration office or Hacienda, depending on the kind of ID.

Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.

POSThttps://api.kit.forhosting.com/verify/cedula-costa-rica

Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.

curl -X POST https://api.kit.forhosting.com/verify/cedula-costa-rica \
  -H "Authorization: Bearer $KIT_KEY" \
  -H "Content-Type: application/json" \
  -d '{"id":"1-0234-0567"}'
{
  "id": "1-0234-0567"
}
{
  "task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
  "type": "verify.cedula_costa_rica",
  "status": "queued",
  "_links": {
    "result": "/tasks/tsk_…/result"
  }
}

The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.

Per request$0.002

Published price — no tokens, no invented credits. A failed task is never charged.

HTTPCodeMeaning
401unauthorizedMissing or invalid API key.
402insufficient_balanceYour balance doesn't cover the task price.
404unknown_typeThat task type doesn't exist.
429rate_limitedToo many requests. Use the webhook instead of polling.

Read the full KIT documentation →