Contact codes
Generate customer and supplier account codes from the contact name, and fill codes for existing contacts.
Every contact can have an optional account code (for example ACM001). Codes identify customers and suppliers on the contact list, in searches and imports, and on printed documents. See Contacts for how codes behave.
You can always type a code on New Contact or Contact → Details. This page adds codes for you.
Where to manage
Settings → Contact codes (Preferences, under Document numbering). You need permission to manage contacts (manage:contacts) to change the setting or fill codes.
How codes are built
A generated code is the first three letters of the contact name and a three-digit number:
| Contact name | Code |
|---|---|
| Acme Traders | ACM001 |
| Acme Holdings | ACM002 |
| Drakenstein Bottling Works | DRA001 |
| 4 Ways Motors | WAY001 (digits and spaces are skipped) |
| Émile & Co | EMI001 (accents are dropped) |
| Jo | JOX001 (short names are padded with X) |
The number follows the highest existing code with the same three letters, including deleted contacts, so a generated code is never handed out twice. After ACM999 comes ACM1000.
Generate codes for new contacts
Turn on Generate codes for new contacts. From then on, a contact saved without a code gets one. This applies to:
- the New Contact form (the code field shows Auto),
- contact CSV imports (rows without a code),
- the REST API and MCP
create_contact, - contacts created by the Stripe and store (Shopify / WooCommerce) syncs.
A code you type is always kept. It is off by default. Turning it off does not remove existing codes.
Fill missing codes
Fill missing codes gives every existing contact without a code a generated one, oldest contact first. Contacts that already have a code are not changed, so it is safe to run again. It works whether or not automatic codes are on.
MCP and in-page tools
| Action | MCP | In-page (WebMCP) |
|---|---|---|
| Read the setting and the count of contacts without a code | get_contact_code_settings | anchor_get_contact_code_settings |
| Turn automatic codes on or off | set_contact_code_auto_generate | anchor_set_contact_code_auto_generate (asks you to confirm) |
| Fill missing codes | fill_missing_contact_codes | anchor_fill_missing_contact_codes (asks you to confirm) |