From the GoReplay team

GoReplay reproduces production bugs. Proof catches them before production.

See Proof
Published on 11/15/2026

What Is GxP Compliance? Rules, Variants and Test Controls

What Is GxP Compliance? Rules, Variants and Test Controls

GxP compliance is a set of good practice requirements that keep regulated products, and the records behind them, accurate, attributable, traceable and protected. The electronic side of that work has a fixed starting point in US law: 21 CFR Part 11 was published in the Federal Register on March 20, 1997 and took effect on August 20, 1997, the date from which an electronic record and an electronic signature could be treated as trustworthy and generally equivalent to paper.

Now the question that catches experienced engineers. You mask the patient names and the card numbers in a captured production trace, replay it against a staging host, and every request comes back clean. Is that test now GxP compliant?

Usually it isn’t, and the reason has nothing to do with how carefully you masked. Masking answers a privacy question. Compliance asks a different one: can you show what data moved, who authorized the replay, what changed on the way, and whether the application’s state afterwards was correct? That gap between “we sanitized it” and “we can defend it” is where most traffic-replay programs in regulated environments stall. Closing it means treating a capture as a regulated data flow rather than a testing shortcut.

What GxP Compliance Means and Why It Matters

Compliance in a regulated industry borrows its logic from evidence handling. A courtroom exhibit is only useful if someone can show who collected it, who handled it, when each transfer happened, and that nothing was altered in between. GxP compliance applies that chain-of-custody thinking to medicines, lab results and trial data: it is a framework of legally enforceable and quality-based requirements covering any activity that can affect the safety, identity, strength, quality, or integrity of a regulated product.

The middle letter of the acronym is a variable. It stands for the activity being regulated, so the same body of thinking wears different names depending on what your system supports. That matters because the name tells you which rulebook applies and, later, which records and controls your test program has to prove.

Where the electronic rules came from

Paper was the default for decades, and the rules assumed it. The change arrived when the FDA published 21 CFR Part 11 in the Federal Register on March 20, 1997, effective August 20, 1997, as recorded in the FDA’s Part 11 scope and application guidance. That regulation set the criteria under which electronic records and electronic signatures count as trustworthy, reliable and generally equivalent to paper records and handwritten signatures.

The reach is wider than most software teams expect. Part 11 applies whenever regulated records are created, modified, maintained, archived, retrieved, or transmitted electronically, and its controls include system validation, restricted access, audit trails, record protection for the retention period, and user accountability. A service that never touches a medicine can still sit inside the scope if it touches the record of one.

A female hospital pharmacist reviewing a batch record document near a large stainless steel product tank.

The batch record in that pharmacist’s hands is the product of a dozen systems: a manufacturing execution platform, a laboratory information system, an inventory database, maybe a monitoring service that logs tank temperature every minute. Each one is a possible GxP system, and each one has to be able to show its own chain of custody.

The decision that comes before any control

Before you pick a tool, a masking rule or a test plan, answer one question: does this system create, change, hold, archive or send a record that supports a regulated decision? If yes, the system is in scope, and the rest of the work is proving its data stays accurate, attributable, traceable, retrievable and protected for as long as you keep it.

Start here: if you can’t name in one sentence which GxP record your test data flows into, you aren’t ready to run the test.

For software teams this history has a blunt consequence. GxP is not a security badge you earn once at launch. It’s a documented control system, and a replay platform is either inside it or outside it, deliberately.

The GxP Family, GMP, GLP, GCP and Their Peers

Five variants cover most of what software teams meet in practice. Read the table like a map: start with the activity your system supports, not with the acronym you’ve heard most often.

VariantRegulated ActivityTypical Scope for SoftwareCore Reference
GMP (Good Manufacturing Practice)Making and testing medicines and devicesBatch release, production records, quality control systems21 CFR Parts 210 and 211 in the US; EU GMP guidelines in Europe
GLP (Good Laboratory Practice)Nonclinical safety studiesLab data systems that support safety submissions21 CFR Part 58 in the US; OECD GLP principles internationally
GCP (Good Clinical Practice)Clinical trials with human participantsTrial data systems, consent records, case report formsICH E6 guideline
GDP (Good Distribution Practice)Storage and transport of medicinesCold-chain monitoring, warehouse and shipping recordsEU Guidelines on Good Distribution Practice
GPvP (Good Pharmacovigilance Practice)Safety monitoring after approvalAdverse event reporting and signal management systemsEU GVP modules

How to pick your row

Work from the system outward. A platform that assembles batch records for release sits in the GMP row. A toxicology data store feeding a safety submission is GLP. A trial management system holding consent forms and case report data is GCP, and its evidence expectations come from ICH E6 rather than from a manufacturing annex.

The rows aren’t exclusive, which is where newcomers get lost. A contract research organization running nonclinical studies while also managing trial data for a sponsor can sit under GLP and GCP at once, and its quality system has to satisfy both without inventing two separate validation programs. Add a distribution arm and a third row joins the file.

References differ by region

The reference column matters because the same principle gets written down differently in each market. A US manufacturer answers to the 21 CFR parts; a European one answers to the EU GMP guidelines; a trial run across both has to satisfy ICH E6 and the local implementation of it. Identify which regulator your product answers to before you draft a single test protocol.

Device makers arrive from a different direction. A printed surgical implant still needs a production record, a validated process and traceable material genealogy, which is why American Additive Manufacturing’s medical device work belongs to a device quality system rather than a drug one, even though the underlying record-keeping logic looks familiar.

The practical rule is short. Identify the variant first, because it decides which records and which controls your test program must prove, and nothing downstream gets easier if you guess wrong.

Core Principles, Data Integrity, ALCOA+ and Audit Trails

Data integrity isn’t a property of a file. It’s a property of a lifecycle: a record has to stay trustworthy from the moment it’s generated, through recording, processing, review, retention and retrieval, all the way to disposal. The EMA’s GMP guidance frames the expectation as ALCOA, that data should be attributable, legible, contemporaneous, original or a true copy, and accurate, and it stresses that metadata must support a complete, accurate, traceable record and let someone reconstruct the activity later.

The five words, and the four that extend them

Attributable means the entry names who made it. Legible means it stays readable for the whole retention period, in a format that doesn’t depend on software you might stop licensing. Contemporaneous means it was recorded when the work happened, not rebuilt a week afterwards from memory and loose notes. Original means the first capture is preserved, or a verified true copy of it. Accurate means the value reflects what occurred.

ALCOA+ adds complete, consistent, enduring and available. Those four are the ones engineering teams skip, because they’re about metadata and time rather than the number on the page.

A diagram illustrating ALCOA+ principles for data integrity across the lifecycle from generation to disposal.

In a replay setting, the lifecycle view changes what you store. A capture isn’t enough on its own: you also need timestamps, source and destination context, request and response relationships, any transformation or masking history, the replay configuration, the operator identity, and the outcome log. Overwrite the original capture or edit a payload, and reconstruction becomes impossible.

What an audit trail actually does

An audit trail records who created or changed an entry, when, and why, without deleting what was there before. Corrections arrive as new, visible entries. Silent overwrites are the failure mode.

A pH reading logged as 6.8 at 14:02 and corrected to 7.1 after review must keep both values, the reviewer’s identity, the second timestamp and a reason such as “electrode recalibrated, re-read per SOP”. If the 6.8 vanishes, the record stops being reconstructable and the correction becomes an unexplained edit.

PrincipleWhat It RequiresTraffic Replay Example
AttributableEvery entry names who created or changed itReplay log shows the operator who started each run
LegibleReadable for the full retention periodCaptures stored in a documented, readable format
ContemporaneousRecorded when the activity happensTimestamps set at the moment each request is captured
OriginalThe first record or a verified true copyRaw capture kept unchanged beside any masked copy
AccurateMatches what actually happenedPayloads replayed without silent edits
CompleteIncludes all data and metadata, including changesRequest and response pairs plus masking history retained
ConsistentSequence and timing follow a logical orderTimestamp precision preserves event ordering
EnduringSurvives the retention periodArchived captures and configurations kept under retention rules
AvailableRetrievable for review or inspectionReplays reproduced from archived inputs on request

Teams who want these requirements translated into system behaviors can work from a 21 CFR Part 11 checklist for engineering and QA, which is faster than reading the regulation cold. The same discipline shows up in the physical lab, where batch record and lab data documentation requirements follow the identical logic about originals, corrections and who signed off.

The test you can apply to any record is simple. Can a reviewer reconstruct exactly what happened, who did it, and when, without asking the author? If the answer needs a conversation, the record isn’t finished.

Validation and Change Control for Software and Test Tools

Validation is documented evidence that a system does what its intended use requires, and keeps doing it. That definition sounds soft until you write it out as a sequence: define intended use, write requirements, assess risk, test against those requirements, record the results, and get Quality’s approval before release. Skip a step and the evidence stops connecting to the claim.

The part that surprises developers is “keeps doing it”. A one-time approval before deployment isn’t sufficient. The EU’s GMP Annex 11, which governs computerized systems used in medicinal-product manufacturing, requires organizations to keep stored data accessible, readable and accurate throughout the retention period, and to check that stored data still holds those properties, as the European Commission’s Annex 11 text sets out. It also expects system evaluations to weigh functionality, deviation records, incidents, problems, upgrade history, performance, reliability, security and validation status.

Change control is the gate, not the paperwork

Every upgrade, patch, integration, configuration change or new test environment passes through an impact assessment. One question drives it: does this change touch a GxP record, or a result used in a release decision?

Say your team upgrades the load-testing tool. If its reports feed a release decision, the upgrade changes the evidence behind that decision and needs revalidation evidence. If the tool only produces throwaway performance charts nobody signs against, the assessment says so and the effort drops accordingly. Same upgrade, two different answers, both defensible because someone wrote down the reasoning.

The documents an inspector will ask for

  • Validation plan: what will be tested, against which requirements, and who approves the outcome.
  • Requirements traceability matrix: the mapping from each requirement to the test that proves it.
  • Test evidence: raw results, timestamps, operator identity and any deviations raised.
  • Change records: what changed, why, who assessed the impact and who authorized it.
  • Approved SOP: how the tool is configured, operated and archived, in language a new hire can follow.

Triggers for an impact review

  1. Any upgrade, patch or new version of the replay or load-testing tool.
  2. Any change to masking rules, capture filters or replay configuration.
  3. Any new integration, target environment or test host.
  4. Any change to operator, admin or approver roles.
  5. Any failed or deviating replay that feeds a release decision.
  6. Any change to the time source, storage location or archive format.

Each trigger opens a change record and an impact assessment before the change goes live. Written down and adopted as-is, that list does most of the work of staying in a validated state, because it removes the judgement call about whether a small change is “really” a change. Small changes are what break validated systems.

Test Data, Environments and Traceability Controls

Could a sanitized production capture still be unsuitable for GxP testing? Yes. Removing names or other direct identifiers does not by itself make a dataset compliant. Sensitive health information, manufacturing details, persistent identifiers or timestamps may remain, and transformations can change what a test demonstrates. Annex 11’s data integrity expectations apply generally across the data lifecycle, so teams should be able to account for how records are handled and preserved.

Six controls that make a dataset defensible

  1. Classify each captured field. Record its sensitivity and relevance to GxP. A device serial number may be harmless in one context and link to a patient in another.
  2. Define masking or tokenization rules and validate them. Confirm that the transformed record remains suitable for its intended test. Making data unreadable is not enough if the transformation removes information the test needs.
  3. Separate production, validation and test environments. Use distinct credentials and access lists, with no shared administrator account spanning environments.
  4. Remove unsuitable requests and rewrite the sample for an isolated target. Block or stub external effects such as payments, email and third-party calls. This is the second step in the replay workflow: the sample must be safe to run before performance or behavior is assessed.
  5. Keep the raw capture read-only. Maintain a lineage log that records each transformation and the rule version applied to each field.
  6. Compare the sanitized dataset with the original. Show that it still represents the workload it is intended to test.

Treat a support inquiry as another data boundary. Leave credentials and production request data out of provider inquiries. The inquiry form asks users to omit both, a sound practice for supplier conversations generally.

Realistic test data and regulated data are different things. Realistic data can produce believable defects. Regulated data also has a documented source, a validated transformation, an access boundary and a disposal date. A dataset may be realistic without being regulated. Once its output is used as evidence, its origin and handling need to be traceable.

That traceability applies to physical materials as well as data. A lab’s records for handling bacteriostatic water illustrate the same basic principle: documentation should let a reviewer reconstruct how something was handled, even if they were not present. For test data, the equivalent record follows the capture through classification, transformation, access, use and disposal. Anonymization alone cannot provide that chain.

Where Traffic Replay Fits Among Risks and Settings

Not every replay carries the same weight, and not every function deserves identical rigor. The FDA’s Computer Software Assurance framework recommends scaling testing effort to the potential impact of a software function on product quality, patient safety and data integrity, so high-risk functions may justify scripted or hybrid testing while lower-risk ones can use lighter evidence, as the FDA’s CSA guidance describes. Each risk below maps to a GxP-relevant attribute: reproducibility, event ordering, or the confidentiality of what you captured.

RiskControlRecommended Configuration
Replay triggers real external effectsIsolated target with outbound calls blockedReplay to an isolated host; stub payment, email and third-party endpoints
Altered payloads make defects unreproducibleOriginal capture kept unchangedStore captures read-only; log each transformation with its rule version
Missing session context creates false defectsVerified session correlationConfirm correlation against sample user flows before trusting results
Clock drift misorders eventsSynchronized time sourcesSync test hosts to a central time source; record timestamp precision in the replay log
Passing replay hides wrong application stateState comparison against expected behaviorCompare status codes with post-replay record values such as order totals

The same mapping, drawn for a test plan you can hand to Quality:

A table outlining various traffic replay risks, corresponding mitigation controls, and recommended technical configuration implementations.

Replay is not automatically a validation activity, so work the decision in order. Define the intended use of the replay. Identify which data and behaviors are GxP-relevant. Assess the risk each one carries. Choose the approach, whether replay, scripted tests or a hybrid, with rigor matched to that risk. Document the evidence and get Quality’s approval before it counts.

Then check correctness, not just completion. A replay that finishes with zero errors proves the tool ran. It doesn’t prove the application behaved. Compare the target response and the resulting application state against expected behavior: a replay can return status 200 for every request while the order total written to the database is wrong, and only the state comparison catches it.

Our own measurement step works this way, comparing responses and application state, because a successful replay on its own never establishes correctness.

Confirm Intended Use Before You Replay Production Traffic

One deliverable comes before any of this: a one-page intended-use statement, written and signed before a replay touches regulated data. Fill in six fields.

  1. GxP variant and governing reference. For example GMP under 21 CFR Parts 210 and 211, or GCP under ICH E6.
  2. Records and results the replay touches, and whether they feed a release decision.
  3. GxP-relevant data and behaviors, each paired with its masking or tokenization rule.
  4. The test approach chosen for that risk level, with the reasoning that got you there.
  5. The isolated target, plus the external endpoints blocked or stubbed.
  6. The Quality approver and the approval date.

Keep the signed statement with the test evidence. When someone asks in eighteen months why a function got scripted tests instead of replay, the answer is in field four, in writing, dated before the work started.

If you’re evaluating GoReplay, test its features against those fields rather than switching them on by default. The debugging and reproduction feature lets you inspect a captured request, replay a filtered sample and compare the target response with expected behavior, which supports field four directly. Capture after TLS termination so the payload is readable, and aim replay only at the isolated target in field five. The PRO edition adds S3 capture storage and replay, keep-alive TCP session recognition, dedicated support and a commercial license on top of the Open Source edition, and the question worth asking is whether those additions earn a place in your validation file or add another supplier to qualify.

Where masking is concerned, a workflow built for sensitive data protection in replay pipelines is easier to evidence than one bolted together per project, because the rules live in configuration rather than in someone’s memory.

Draft the intended-use statement before your next replay run. Everything else, the masking rules, the environment segregation, the audit trail, the state comparison, hangs off that one page.


Replaying production traffic into a test environment is how you find the defect that only shows up under real request shapes, and GoReplay was built for exactly that: capturing live HTTP traffic and replaying it against an isolated target while you keep the evidence a reviewer will ask for. Pair it with the controls in this article, intended use first, masking rules second, state comparison always, and a replay becomes something you can hand to Quality instead of something you hope nobody audits. Start at GoReplay and run your first controlled capture this week.

Ready to Get Started?

Join these successful companies in using GoReplay to improve your testing and deployment processes.

Talk to the GoReplay team

Describe what you want to capture or replay, your deployment, and any PRO requirements. Or email [email protected].

Please leave out credentials and production request data.