</>Seif Ashraf
← All projects
Own product · live

Khatm — Bilingual Tax Invoices for Saudi Businesses

Invoicing for small businesses in Saudi Arabia: tax invoices in Arabic and English on one A4 page, with the ZATCA QR code, payments, credit notes and the quarter's VAT.

Built for: Freelancers, studios and small companies in Saudi Arabia that send a handful of tax invoices a month, shown through a demo design studio in Riyadh with six months of history.

Opens in a new tab — my own product, with a live demo you can use.

Real screenshot of the live product — click it to open the demo.

Khatm overview: SAR 52,268.50 owed across five invoices, a breakdown by how late each is, money received this month, VAT on this quarter's sales and six months of sales as bars.
The overview says what you're owed as a sentence, then how late it is.
The same Khatm overview in Arabic, laid out right to left.
The whole app works in Arabic, right to left.
Khatm VAT return screen for Q4 2026: standard-rated sales, zero-rated, exports, exempt and out of scope, with the VAT due.
The sales side of the VAT return, net of credit notes, ready to download.

The problem

Saudi tax invoices have to be bilingual, carry the seller's and buyer's VAT details, round VAT the way ZATCA does and include a QR code. Small businesses still make them in Word or Excel, renumber them by hand, retype the total in words, and fix mistakes by editing an invoice that was already sent, which the rules don't allow.

The solution

You write a tax invoice, a simplified invoice or a quotation once and Khatm lays it out in Arabic and English on one A4 page: Umm al-Qura dates under the Gregorian ones, VAT per category to the halala, the total in words in both languages, bank details and the business's own round seal. Issuing numbers the document, freezes both parties and writes the QR code; after that it can't be edited, and mistakes are corrected with a credit note that points back to the invoice. Each document gets a private link the customer opens in their own language. Payments and credit notes settle invoices, and the overview shows what's owed, how late it is and the VAT due this quarter.

What it does

One page in two languages

English from the left, Arabic from the right, whatever language the app is in. The editor draws the page live as you type, and the print stylesheet gives an exact A4 page.

ZATCA QR code

The phase-one QR (seller, VAT number, time stamp, total and VAT as TLV fields) is tested against ZATCA's published example and against Arabic seller names, where lengths are counted in bytes.

Numbers with no gaps

A document is checked, locked and numbered in the same database update that moves the sequence on, so two invoices issued at the same moment can never share a number.

Amounts in words, both languages

Arabic counting rules handled properly: ريالان، ثلاثة ريالات، أحد عشر ريالًا، ألفا ريال. Tested on the awkward cases up to billions.

Payments and credit notes

Part payments, transfers, cash or card. Credit notes can never add up to more than the invoice, and accepted quotations turn into draft invoices with the same lines.

The quarter's VAT

Standard-rated, zero-rated, export, exempt and out-of-scope sales, each net of credit notes, with the VAT due and a CSV download.

Why it mattersto the business

  • Invoices that meet ZATCA's first phase without retyping anything in two languages.
  • No duplicate or missing invoice numbers, even when two people issue at once.
  • The owner sees who owes what and how late, and the VAT figure for the return, without a spreadsheet.
  • Customers get a link in their own language with the IBAN to pay into.

Technology

Next.js 16 (App Router, Cache Components, Server Actions)React 19TypeScriptPostgreSQL (Neon)Drizzle ORMTailwind CSS 4Vercel + Vercel CronVitest + GitHub Actions

About this project: My own product, designed and built end to end. It is not client work and hasn't been certified by ZATCA; it covers the first phase (the QR code), not the second (clearance through FATOORA). "Open the demo" gives every visitor a private copy of a made-up design studio with six months of invoices, deleted after a day. The code is public at github.com/darkxgs/khatm.

Want something like thisfor your business?

This is my own product, live with a demo you can try. If your business needs something like it, I can set it up for you or build the version that fits how you work.