Skip to content
HNROS Help Center
English
Start free
Contents1. What this section is for2. Template syntaxExamplesRules3. The e-Fatura / e-Arşiv / e-İrsaliye format4. Resetting every year5. Filters and the order in which a series is chosen6. The series that come ready-made7. The series selector on the document screen8. When the number is assigned, and why it never changes9. Counter correction10. How to change a series that has issued numbers11. Bank matching and accounting vouchers12. On the phone (Garden + Step)13. Error codes

Help › Settings and Log › Document Number Series

Document Number Series — A Guide from Scratch

Every final document — invoice, delivery note, order, quotation, receipt, cheque batch — has a number that is shown to the customer, the accountant and the tax office. HNR generates this number from a series template that you define: a fixed prefix, optionally the year, and a zero-padded sequential number. For example art00001, SF2026000001 or, in the GİB e-Fatura format, ABC2026000000001. The number is assigned once, when the document is saved, and never changes again.

1. What this section is for

A document number has two parts: the series template (the format of the number) and the sequence (the next number from the series counter). Series are used for eight document types: invoice, delivery note, order, quotation, business partner receipt, cash receipt, bank receipt and cheque batch.

Where to open it. Settings › Company details › Document series. Only the system administrator adds and edits series and corrects counters; other users only choose in the series selector on the document screen (section 7).

2. Template syntax

A template is a short text that says how the number is written. The parts in curly braces are placeholders; everything else is written as it is.

Part Meaning
plain text Letters, digits and . _ / -. Upper and lower case are kept (art stays lowercase).
{seri} The series code (e.g. ANK).
{yyyy} The year of the document date, 4 digits (2026).
{yy} The year of the document date, 2 digits (26).
{00000} The sequential number. The number of zeros is the number of digits (1-12); the number is padded with zeros on the left. A template must contain exactly one.

Examples

Template Series code First number
art{00000}ARTart00001
SF{yyyy}{000000}SFSF2026000001
{seri}-{yy}/{0000}ANKANK-26/0001
ABC{yyyy}{000000000}ABCABC2026000000001

Rules

Preview. While you type the template, the preview box below it shows the first number live — and, for a series that resets yearly, next year's first number too. If a rule is broken it turns red; fix it before saving.

3. The e-Fatura / e-Arşiv / e-İrsaliye format

The number of a GİB e-document is 16 characters: a 3-character prefix (uppercase letters or digits) + a 4-digit year + a 9-digit sequence. In HNR this is exactly the template ABC{yyyy}{000000000} → ABC2026000000001.

This setting only determines the format of the number. Sending the document to GİB is a separate step.

4. Resetting every year

If Restart from 1 every year is ticked, the series has a separate counter for each calendar year, and the year is taken from the document date (not from the day of saving): a document dated 2026 gets SF2026000017, while a document dated 2025 entered on the same day continues the 2025 counter. That is why such a series must have {yyyy} or {yy} in its template — otherwise two years would produce the same numbers. A series without the tick has a single counter that keeps growing over the years (art00001, art00002, …).

5. Filters and the order in which a series is chosen

A type can have several series: for example so that sales and purchase invoices, two branches, or the shop and the B2B portal are numbered separately. Filters decide which document takes its number from which series. An empty filter covers all of them.

Filter What it looks at
Kind The invoice kind (1 sale, 0 purchase, 3 sales return, 2 purchase return, 9 retail sale…), the delivery note kind, the receipt type or the cheque batch operation (CG, CC, BT, IG, IC, DV). Several values are written comma-separated.
Warehouse / branch The document's warehouse. Branches are told apart by warehouse code (e.g. ANKARA,IZMIR).
Channel Where the document was entered: Desktop, Mobile, B2B portal, Field sales, External API.

When a document is saved, the series is determined in this order:

  1. The series the user chose on the document. It must be active, of the same type and suitable for the document's kind/warehouse/channel; otherwise BELGE_SERI_UYUMSUZ.
  2. The most specific series. Among the active series that pass the filters, the one with the most filled-in filters wins.
  3. The default series. If several candidates are equally specific, the one marked as default is chosen.
  4. It is asked on the document. If it is still ambiguous, the document is not saved; BELGE_SERI_SECIM_GEREKLI opens the series selector on screen. If no series fits at all: BELGE_SERI_YOK.

Example. There are the series SF (kind filter: sales kinds) and ANK (kind: sales kinds + warehouse: ANKARA). A sales invoice issued from the Ankara warehouse takes its number from ANK (two filled-in filters, more specific); sales invoices from the other warehouses take theirs from SF. There cannot be two default series with the same filter (BELGE_SERI_VARSAYILAN).

6. The series that come ready-made

If no series has been defined for a document type, HNR adds a default series for that type when the company opens (it appears in the audit trail as "System default"). All of them reset yearly and use a 6-digit sequence; you can edit them, deactivate them or create new ones as you like. Invoices get two series: SF numbers issued invoices (the kinds on the sales side: sale, purchase return, export…), AF numbers received invoices (the kinds on the purchase side: purchase, sales return…).

Code Document type Template First number (2026)
SFInvoice (sales side)SF{yyyy}{000000}SF2026000001
AFInvoice (purchase side)AF{yyyy}{000000}AF2026000001
IRDelivery noteIR{yyyy}{000000}IR2026000001
SPOrderSP{yyyy}{000000}SP2026000001
TKQuotationTK{yyyy}{000000}TK2026000001
CMBusiness partner receiptCM{yyyy}{000000}CM2026000001
KMCash receiptKM{yyyy}{000000}KM2026000001
BMBank receiptBM{yyyy}{000000}BM2026000001
CBCheque batchCB{yyyy}{000000}CB2026000001

7. The series selector on the document screen

On the invoice, delivery note, order, quotation, receipt and cheque batch screens, the Document number series box appears only when more than one series fits the document. If only one series fits, it does not appear at all and the number comes from that series.

8. When the number is assigned, and why it never changes

9. Counter correction

The Counter button on the series' row opens the counter correction form. It is used so that numbering continues where it left off when you move over from a paper ledger or an old program.

10. How to change a series that has issued numbers

Once a series has issued its first number, its template and its yearly reset rule are locked (BELGE_SERI_KULLANILMIS); on the form these fields are greyed out. The name, the filters and the default and active marks can still be changed. To change the format:

  1. Create a new series with the new format.
  2. Untick Active on the old series (deactivate it).
  3. Old documents keep their old numbers; new documents take their numbers from the new series.

Deleting is possible only for a series that has never issued a number; a series that has issued numbers is not deleted but deactivated. The document type of a series cannot be changed later either.

11. Bank matching and accounting vouchers

12. On the phone (Garden + Step)

On a small screen the series list appears as cards: code, document type, name, next number and the Default / Inactive / e-Document badges; each card has Edit, Counter and (if it has issued no number) Delete buttons. A new series or an edit is done with a four-step wizard:

  1. Type — document type, code and name.
  2. Template — template, yearly reset, e-Document format and live preview.
  3. Filter — kind, warehouse/branch, channel, default and active.
  4. Confirm — summary, first number and justification; Save.

You cannot move on until the required fields of a step are correct. The series selector on document screens works on the phone too, with the same rules and a large touch target. For the phone interface see Mobile.

13. Error codes

Code What it means What to do
BELGE_SERI_SECIM_GEREKLI Several series fit equally well and there is no single default among them. Choose a series in the box on the document; or make one of the series the default, or narrow the filters.
BELGE_SERI_UYUMSUZ The chosen series is inactive, belongs to another type or does not fit the document's kind/warehouse/channel. Set the box to "Auto" or choose a suitable series.
BELGE_SERI_YOK There is no active series for this document type, or the requested series code was not found. Create a series in Settings › Document series, or make an inactive series active again.
BELGE_SERI_KORUMA An attempt was made to change the number or series of a final document, or the document type of a series. The number is kept. If necessary, cancel the document and issue a new one.
BELGE_SERI_KULLANILMIS An attempt was made to change the template or reset rule of a series that has issued numbers, or to delete it. Create a new series and deactivate the old one (section 10).
BELGE_SERI_CAKISMA Another active series of the same type could produce the same numbers. Change the fixed part (prefix) of the template.
BELGE_NUMARA_SERI_DOLU The digits of the number field are used up; no number was assigned. Create a new series with a wider number field and deactivate the old one.
BELGE_SERI_SAYAC_GERI An attempt was made to set the counter below a number already issued in that period. The counter can only be moved forward (section 9).

The definition form may also show these codes: BELGE_SERI_SABLON (the template rules in section 2), BELGE_SERI_EBELGE (the e-document pattern, section 3), BELGE_SERI_VARSAYILAN (a second default series with the same filter), BELGE_SERI_GEREKCE (the justification of a counter correction is shorter than 5 characters).

Related guides: Settings and Log · Document Entry · Bank transaction import · Accounting · Mobile.