In short: SFDA’s drug track and trace system, RSD, requires every pharmaceutical manufacturer in Saudi Arabia to do three things: print a GS1 DataMatrix with a unique serial number on each pack, aggregate packs into cases and pallets, and report every movement to RSD electronically. Success depends on the packaging line and the data system working as one, not on the printer alone.
Picture a blister line running 120 cartons a minute. The QA supervisor finds that a full batch was shipped without being reported to RSD. The distributor refuses to accept it, and the order comes back to the warehouse. This happens when RSD is treated as a printing project instead of a data system.
The short answer: a plant must know what to print, how to aggregate, and when to report. This guide explains SFDA’s requirements as written in its official specifications, how the solution works on the line, the mistakes we see most, and what drives cost and timeline.
Key takeaways
- Every saleable pack carries a GS1 DataMatrix with four data elements: GTIN, expiry date, batch number and a unique serial number.
- Cases and pallets are identified by an SSCC or a GTIN plus serial number, and linked to everything inside them (aggregation).
- The manufacturer sends events such as Supply and Dispatch to RSD through web services; the receiver confirms with Accept.
- The hard part is usually aggregation and ERP integration, not printing.
What is the SFDA RSD track and trace system?
RSD is the Saudi Food and Drug Authority’s system for tracking human medicines, whether made locally or imported, from the manufacturer to the pharmacy or hospital. SFDA launched the full system at the end of 2018 and stakeholders started using it in early 2019. Its stated goals: stop counterfeit drugs, monitor drug availability, and locate products fast during a recall.
How does RSD compliance work on a packaging line?
The solution runs in four layers, each passing its data to the next:
- Serialization: the system generates random serial numbers per GTIN, and the line printer encodes them in a DataMatrix with batch and expiry.
- Camera verification: a vision system reads every code, checks content and print quality, and rejects bad packs automatically.
- Aggregation: packs going into a case are scanned and linked to the case ID; cases are then linked to the pallet SSCC.
- Reporting: a Level 4 platform sends Supply events for produced packs, then Dispatch events at shipping. A full shipment can be reported with one aggregation file instead of pack by pack.
The result: every pack on the market can be traced to its source, batch and receiver, and anyone can check it with the SFDA app.
SFDA serialization requirements in detail
| Requirement | What the SFDA specification says | What it means for the line |
|---|---|---|
| Symbology | 2D GS1 DataMatrix, GS1-encoded | A printer that produces DataMatrix at consistent read quality |
| Data in the code | GTIN, 14 digits (AI 01); expiry YYMMDD (AI 17); batch up to 20 characters (AI 10); serial up to 20 characters (AI 21) | Printer fed from the batch record, not manual entry |
| Serial numbers | Random, unique per GTIN, stored by the manufacturer’s system | A system that generates, stores and blocks duplicates |
| Human-readable text | GTIN and serial next to the code; expiry in readable form | Artwork with enough space for code and text |
| Aggregation | Mandatory since 1 October 2019 for cases and pallets; 18-digit SSCC or GTIN plus serial | Aggregation station and reader at end of line; pallet labels never reused |
| Reporting | Supply, Dispatch, Deactivate, Export and Return events via SOAP web services with SFDA-issued credentials | A Level 4 system connected to ERP that reports on time |
The specification exempts some cases from the 2D barcode, such as free samples, drugs imported for repackaging, and small named-patient orders.
What happens to a pack after it leaves the plant?
The plant’s responsibility does not end at the gate. SFDA’s integration guide defines a full lifecycle per pack, and the manufacturer starts it:
- Supply: the plant registers locally produced packs in RSD. This is the first step in a pack’s life.
- Dispatch: at shipping, the plant reports what went to the distributor, by serial, by batch, or with a shipment aggregation file.
- Accept: the receiver confirms. If the dispatch does not match what arrived, the shipment stalls.
- Deactivate: damaged, expired or recalled packs are removed with a reason.
- Export and Return: for packs leaving the Kingdom or going back to the sender, each with a cancel event for corrections.
That is why a small aggregation error inside the plant shows up later at the distributor as a rejected shipment or stuck stock.
Illustrative example from a Saudi factory
The scenario below is illustrative, based on common situations in pharmaceutical plants, not a specific client.
A generics plant runs two tablet packaging lines. Serialization works, but aggregation is manual: an operator types case numbers into Excel, and someone uploads the file to RSD at the end of the day. Every week there are gaps between what shipped and what was reported, and shipments get delayed when the distributor cannot accept them.
The fix was an aggregation station with a reader on each line, plus a Level 4 platform that pulls the batch order from ERP, sends Supply when the batch closes, and sends Dispatch with the aggregation file when the shipment leaves. The gaps disappeared because no number passed through a human hand anymore.
If your lines look like this, book a free consultation to review their readiness.
Where do ERP and MES fit?
ERP knows batch orders, products, customers and shipments. RSD needs the same data at single-pack level. Between them sit two layers: the line system (Level 2 and Level 3) that prints, verifies and aggregates, and the Level 4 platform that manages serial numbers and reports events.
If the plant runs an MES, it is the natural home for the line batch order and verification results. If not, the Level 4 platform takes the batch order straight from ERP. What matters is that no number is re-keyed between layers.
RSD implementation steps for a pharma plant
- Map products and packs: GTIN per product and pack size, and the aggregation levels each one needs.
- Assess the lines: speed, existing printers and cameras, and space for new stations.
- Design the solution: what goes on the line, where serials are managed, and how the system connects to ERP and RSD.
- Install and qualify: equipment and software, then IQ/OQ/PQ in line with GMP.
- Connect and test with RSD: test the events with the plant’s credentials before go-live.
- Train and go live: production, warehouse and QA teams trained on rejects, cancellations and re-aggregation.
Common RSD compliance mistakes
- Sequential or Excel-generated serials: the specification requires random, unique serials stored by the plant’s system.
- Manual aggregation: the biggest source of gaps between shipped and reported.
- Ignoring rejects and QC samples: every destroyed or sampled pack must be handled in the system, or it stays open.
- RSD disconnected from ERP: means re-keying, late events and quantity errors.
- Weak print quality: a code that reads at the plant may fail at the distributor or pharmacy.
Quick readiness checklist
- Does every product and pack size have a registered GTIN?
- Are serials generated randomly and stored in one system?
- Does a camera verify every code and reject failures automatically?
- Are packs linked to cases and pallets without manual entry?
- Are Supply and Dispatch events sent automatically?
- Is there a documented procedure for damaged packs, samples and returns?
Two or more “no” answers usually point to a gap in aggregation or integration, and that is the first thing to fix.
What drives RSD project cost and timeline?
There is no fixed price. Cost and duration depend on clear factors:
- Number of packaging lines and their speed.
- Aggregation levels needed (case only, or case and pallet).
- Existing equipment: can current printers and cameras be reused?
- Depth of integration with ERP and the warehouse system.
- Qualification and documentation requirements.
In our experience, one line with usable equipment and simple integration takes weeks; several lines with full aggregation and ERP integration can take months.
Read also: Pharma and food stock counts by batch and expiry, Warehouse Management System for Factories, and AUTOMERA’s serialization and track & trace solutions within our digital transformation services.
How can AUTOMERA help?
We start by reviewing your packaging lines, packs and current reporting, then propose only what is needed: serialization, verification and aggregation stations, and a Level 4 platform that connects the line to ERP and RSD, with qualification and training through go-live.
Are your packaging lines ready for RSD?
Book a free consultation with the AUTOMERA team. We review serialization, aggregation and reporting on your lines, and map what is missing and how to close it.
Frequently asked questions
Is RSD mandatory for all pharmaceutical manufacturers in Saudi Arabia?
Yes, for human ready-to-market medicines, locally made or imported. The specification exempts specific cases such as free samples and drugs imported for repackaging, and defers herbal, health and veterinary products.
What data does the RSD barcode carry?
Four GS1-encoded elements: the GTIN, expiry date, batch number, and a serial number unique to each pack.
What is the difference between serialization and aggregation?
Serialization gives each pack a unique identity. Aggregation links packs to cases and cases to pallets, so scanning one pallet tells you everything inside.
Can we report to RSD manually without integration?
SFDA provides an online portal, but daily reporting from continuous production lines needs web-service integration, otherwise events run late and errors pile up.
Do we need to replace our line printers?
Not always. Many modern printers produce DataMatrix at sufficient quality; the decision should follow a print-and-read test at real line speed.
Sources: SFDA Drug Barcode Specification (v6.1), SFDA Drug Track and Trace Integration Guide (v2.1, August 2024), SFDA: The Track-and-Trace System. Information current as of November 2026.
