Deterministic accounting rules — not "magic AI"
First things first: no posting in Macct is guessed by an AI. Artificial intelligence is used to suggest account coding, read receipts (OCR) and automate routine work — but the accounting itself follows fixed, deterministic rules. A suggestion never becomes a posting until a human approves it, and once it is posted it is the same double-entry logic as in any serious accounting system.
- Double-entry bookkeeping is enforced. Every voucher must balance (sum of debits = sum of credits) and have at least two lines — the system refuses to save anything else. This is not a warning, it is a hard block.
- AI suggests, the human decides. Coding suggestions (rule-based or model-based) are presented for approval. Account, VAT code and amount are shown before anything is posted.
- Everything is traceable and explainable. Every posting has a voucher with a date, voucher number, counterparty, who entered it and when. Posted vouchers are immutable (Bookkeeping Act § 9) — corrections are made by reversal, not deletion.
- Everything can be inspected. From a report line the path leads to the general ledger, to the voucher, to the individual voucher line. Payroll calculations show each component.
- Controls and validations prevent classic errors. Period locks, VAT term locks, balance enforcement, reconciliation jobs and preflight checks before submission stop errors before they become accounting records.
Contents
Part 1 — Accounting
1. Double-entry bookkeeping — the foundation
Everything in Macct is built on double-entry bookkeeping. A voucher consists of two or more lines, each line is posted to one general-ledger account (NS 4102), and the sum of debits always equals the sum of credits. The voucher nets to zero. The system enforces this at several levels — in the application, and with a database trigger that blocks unbalanced vouchers and any change to posted vouchers.
Each voucher line carries a general-ledger account, an amount (debit or credit), an optional VAT code, and optionally a cost center and project. VAT is calculated deterministically from the VAT code — never guessed.
2. General ledger, sub-ledgers and reports all connect
The vouchers are the single source of truth. Everything else is a view of the same postings:
The sub-ledgers (customers on 1500, suppliers on 2400) are per-partner views of the same voucher lines. A nightly reconciliation job compares the sum of open items per partner against the balance in the general ledger — if they drift apart, it is flagged.
What is a sub-ledger?
A sub-ledger is one general-ledger account specified per counterparty. The general ledger says receivables are NOK 240,000; the customer sub-ledger says which customers they are spread across, which invoices are open, and for how long. Macct has three sub-ledgers, built on the same principle:
The employee sub-ledger is built on the same premise as the other two: the payroll voucher is posted per employee on salary owed (2930), holiday pay owed (2940) and tax withholding (2600), and the sub-ledger reads the general ledger back per person — what the company owes each individual, and what has been withheld from them. The payment debits the same accounts per employee, so the balance reaches zero for the person who actually received the money. A separate nightly job checks that the entire account balance is allocated to a named employee.
3. Accruals and provisions
Costs and revenues belong in the period they relate to. Provisions whose pattern the system knows — holiday pay, employer's national insurance contributions and tax — Macct calculates and posts automatically (see payroll and year-end closing below). Plain accruals, such as a prepaid insurance, are entered as ordinary vouchers on the same principle:
A company pays NOK 12,000 for a full year's insurance in January. The cost belongs to twelve months, not to January alone.
| Event | Account | Debit | Credit |
|---|---|---|---|
| Payment (January) | 1700 Prepaid cost | 12 000 | |
| 1920 Bank | 12 000 | ||
| Accrual (each month × 12) | 6300 Insurance premium | 1 000 | |
| 1700 Prepaid cost | 1 000 |
The income statement is charged NOK 1,000 per month; the remainder sits as an asset (prepaid) until it is expensed.
The matching principle, Accounting Act § 4-1. Provisions per generally accepted accounting principles (NRS 8 for small entities).
4. VAT reconciliation and term settlement
VAT is calculated per voucher line from the VAT code (SAF-T standard codes). Output VAT is booked split by rate — 2710 (25%), 2711 (15%), 2712 (12%) — and input VAT on 1610. The VAT return is code-based: basis and tax are summed per code for the term, the way the Norwegian Tax Administration expects.
| Item | Amount |
|---|---|
| Output VAT, 25% (account 2710) | 50 000 |
| Input VAT, deduction (account 1610) | − 12 000 |
| To pay (VAT payable) | 38 000 |
The settlement zeroes the VAT accounts for the term and posts the net against the settlement account 2740:
| Account | Debit | Credit |
|---|---|---|
| 2710 Output VAT | 50 000 | |
| 1610 Input VAT | 12 000 | |
| 2740 VAT settlement account (payable) | 38 000 | |
| Total | 50 000 | 50 000 |
The VAT Act; bimonthly reporting (6 terms/year) as the general rule.
5. Bank reconciliation
Bank transactions are imported (CSV/PDF, or automatically via PSD2) and matched against the accounting records. Macct suggests coding based on reconciliation rules — the transaction text, direction (in/out) and amount range — but never posts automatically: the suggestion goes to the inbox for approval. Unambiguous matches (a KID or invoice number that matches an open invoice, with the right amount) are proposed as a payment and reconciled against the sub-ledger on approval.
6. Year-end closing and period locks
Year-end closing is a fixed routine with controls at every step — not a "press the button and hope" operation:
NRS 8 (generally accepted accounting principles for small entities); Companies Act § 8-1 for dividends; Accounting Act § 4-3 (congruence) for opening/closing balances.
7. Tax expense, tax payable and differences
For a limited company (AS) the tax is calculated on the taxable result — not the accounting result. The difference consists of permanent and temporary items, tracked in the business specification. Macct calculates and posts tax payable (8300 → 2500) from this basis.
| Item | Amount |
|---|---|
| Profit before tax (accounting) | 500 000 |
| + Permanent difference (non-deductible, e.g. entertainment over the limit) | 20 000 |
| − Temporary difference (excess tax depreciation, declining balance > straight-line) | − 50 000 |
| = Taxable result (basis for tax payable) | 470 000 |
| Tax payable, 22% | 103 400 |
Posting:
| Account | Debit | Credit |
|---|---|---|
| 8300 Tax expense | 103 400 | |
| 2500 Tax payable | 103 400 |
Temporary differences and deferred tax
The temporary difference of NOK 50,000 (tax depreciates more this year, but the difference reverses later) represents a deferred tax of 22% = NOK 11,000. Macct tracks all temporary differences in the business specification, so they are visible and verifiable. The posting of deferred tax / deferred tax assets itself is an accounting judgement that small entities can often simplify (NRS 8) — so Macct posts tax payable and keeps the differences visible in the basis, rather than guessing at a balance-sheet entry that has not been decided. The differences are laid out when they need to be assessed.
The Tax Act (ordinary corporate tax 22%); NRS 8 and Accounting Act § 6-2 on simplification for small entities.
8. Business specification and tax return
The business specification and the company's tax return are built from the posted figures — the accounts are mapped to the tax-return fields via an explicit mapping (never guessed). The flow is a strict four-eyes workflow with an integrity check:
Submission via Altinn 3 / Maskinporten. The XML is validated against the Norwegian Tax Administration's official XSDs per income year.
9. Traceability and audit trail
- Immutability: posted vouchers cannot be changed or deleted (Bookkeeping Act § 9) — enforced by a database trigger. Corrections are made by reversal, which mirrors the original voucher with the opposite sign and links the two together.
- Consecutive voucher numbers per company and year, with no gaps.
- Security log: sensitive events (reopening a period, replacing the opening balance, IDOR attempts) are written to an audit log that the database refuses to change or delete (append-only, also when the other triggers are bypassed with replication mode).
- Event log on the tax return and annual accounts: who did what, when, and the data hash at each step.
- SAF-T export (Financial v1.40) with real opening and closing balances per account and partner — ready for a tax audit.
10. Payroll run step by step
A payroll run is deterministic: the same basis yields the same figures, every time. The run is idempotent per company, year and month.
Each pay slip shows the components individually, so the calculation is verifiable down to the krone.
The employee sub-ledger gives an overview of the money between the business and each employee: salary, holiday pay, travel expenses and deductions go in, the payment goes out, and the balance per employee shows what remains — per date, with the history behind it.
11. Tax withholding
The withholding follows the employee's tax card:
- Percentage card (prosentkort): the same percentage every month, including June and December.
- Table card (tabellkort): withholding per the Norwegian Tax Administration's official withholding table (the withholding routine), with a withholding-free June and half the rate in December.
- Exemption card (frikort): 0% withholding up to the exemption card's amount limit. The limit is read from the tax card; when the year's accumulated pay passes it, 50% (the missing-tax-card rate) is withheld on the excess, with an alert to obtain a new tax card.
The Tax Payment Act; withholding tables from the Norwegian Tax Administration. The June/December adjustment applies only to table cards (Tax Payment Regulation § 5-7-1).
And afterwards: on Deductions and payments, Macct shows what the Norwegian Tax Administration has registered as open — withholding tax, employer contributions and other claims, with due dates, estimated interest and remaining balance, fetched directly from the Tax Administration. When the Tax Administration has allocated your payment, the claim drops off the list.
12. Employer's national insurance contributions
Employer's contributions (AGA) are calculated on the contribution basis — cash salary + holiday pay + benefits in kind + the employer's pension premium (National Insurance Act § 23-2) — at the rate for the employee's zone. The rates are date-driven and read from a versioned, approved rule set. Zone 1a uses the exemption-amount tier: a low rate until the contributions saved compared with the zone 1 rate reach the exemption amount, then the zone 1 rate — accumulated correctly across the year and across payroll runs.
13. Holiday pay
Holiday pay is accrued on an ongoing basis from the holiday-pay basis — 12% by default (4 weeks' holiday + the collectively agreed week), per employee. The provision is booked as a cost (5020) against holiday pay owed (2940), and is included in the contribution basis in the accrual year. When the holiday pay is paid out the following year, the provision is settled.
14. OTP basis (occupational pension)
When mandatory occupational pension (OTP) is enabled, the premium is calculated from the pension basis per employee (with optional inclusion of holiday pay), and booked as an employer cost. The employer's pension premium is part of the contribution basis (National Insurance Act § 23-2 fourth paragraph) — both when posting and in the A-melding. Employees who are not pension members are flagged in the run.
15. Benefits in kind, travel expenses and outlays
Benefits in kind
Taxable benefits in kind (a company car, free phone and the like) increase the withholding and contribution basis, but are not paid out in cash. The valuation comes from an approved rule set — if the rate is not approved, a manual amount is required.
Travel expenses and outlays
Travel expenses are handled per the government rates (subsistence and mileage), and split into a withholding-free part (paid out tax-free, increasing net pay) and a withholding-liable part (the difference against the tax-free rate — into the tax and contribution basis, but not the holiday-pay basis). Approved travel expense claims are pulled into the payroll run automatically — whether payroll is run directly or via the draft flow — and marked consumed when posted so they are not included twice.
16. Sick pay and the employer period
In the event of sick leave, Macct calculates the employer period of 16 calendar days (National Insurance Act § 8-19): the first 16 days are covered by the employer, days beyond that are NAV's responsibility and eligible for reimbursement. Sick-pay reimbursement from NAV is booked (debit 1575 / credit 5800), so the payroll cost in the accounts reflects what the employer actually bears.
National Insurance Act § 8-19 (the employer period).
17. Postings from a payroll run — a complete example
Here is how a payroll run fits together, end to end. One employee, fixed monthly salary NOK 50,000, percentage card 30%, zone 1:
| Component | Amount | Basis / rate |
|---|---|---|
| Gross salary | 50 000 | Fixed monthly salary |
| Tax withholding | − 15 000 | Percentage card 30% |
| Net salary (paid out) | 35 000 | |
| Holiday pay provision | 6 000 | 12% of 50 000 |
| Employer's contributions | 7 896 | 14.1% of (50 000 + 6 000) |
| Account | Text | Debit | Credit |
|---|---|---|---|
| 5000 | Salary | 50 000 | |
| 2600 | Tax withholding (owed) | 15 000 | |
| 2930 | Salary owed (net) | 35 000 | |
| 5400 | Employer's contributions | 7 896 | |
| 2670 | Employer's contributions owed | 7 896 | |
| 5020 | Holiday pay provision | 6 000 | |
| 2940 | Holiday pay owed | 6 000 | |
| Total (the voucher balances) | 63 896 | 63 896 | |
Voucher type "manuell", generated in full by the payroll run. Every line can be inspected, and the slip shows the components per employee.
18. A-melding, term settlement and reconciliation against the accounts
A-melding
The A-melding is built from the payroll run — income per recipient, tax withholding and employer's contributions per zone — ready for submission to Altinn. It is never submitted automatically. A step-by-step guide shows the flow: download → altinn.no → upload → check and send.
Term settlement
Employer's contributions are paid on the 15th of the month after the end of the term (Tax Payment Act § 10-10). From 1 January 2026, withheld tax is paid directly to the Tax Administration no later than the first business day after the salary payment (the separate withholding account is abolished). These, and the VAT and advance-tax deadlines, are in the deadline calendar.
The payment itself is made in your online bank, with a KID to the Tax Administration's account 7694 05 24802. Macct computes the KID following the Tax Administration's structure (a new KID per month for withheld tax, one per term for employer's contributions) and puts the amount, KID, account and due date ready under «Deductions and settlement» — with a copy button. When the bank row arrives, the payment is registered and reconciled against the voucher in one click, and accounts 2600 and 2670 net to zero. The a-melding feedback is used to check that the KID matches the Tax Administration's.
Reconciling payroll against the accounts
Because the payroll voucher is generated directly from the run, payroll and accounting agree by construction: gross salary on 5000, tax withholding on 2600, employer's contributions on 5400/2670, holiday pay on 5020/2940. The totals on the payroll run are the same as in the A-melding and in the general ledger — there is no "shadow ledger".
The same holds per employee: the employee sub-ledger reads 2930, 2940 and 2600 back from the general ledger, person by person, and shows how much of the account balance is allocated to an employee — and how much is not.
Which accounts does the payroll module use?
| Account | Use |
|---|---|
| 5000 | Salary (cost) |
| 5020 | Holiday pay provision (cost) |
| 5400 | Employer's contributions (cost) |
| 2600 | Tax withholding owed |
| 2670 | Employer's contributions owed |
| 2930 | Salary owed (net) |
| 2940 | Holiday pay owed |
| 1575 / 5800 | Sick-pay reimbursement from NAV |
A complete Norwegian accounting and payroll system
Macct covers journal entries, invoicing, VAT, banking, year-end closing, the tax return, payroll and the A-melding — with the same controls a serious accounting system demands. AI gives you speed; the rules keep the accounts safe.
Read also: Accounting deadlines · What is a voucher? · Meets the legal requirements · Rules & laws · Keep the books yourself