promptfoo data protection testing for GDPR

The promptfoo gdpr preset tests AI systems for personal data exposure, access-control and deletion-flow issues. It produces technical evidence, not a legal compliance determination.

On this page

How promptfoo GDPR testing fits an AI data protection program

When an AI feature processes personal data, the privacy or security team needs evidence that data protection was tested, not just promised. The promptfoo gdpr preset produces technical test results for personal data exposure, access control and deletion flows. It does not certify GDPR compliance and it does not replace privacy counsel. Treat its output as risk discovery that feeds your privacy program, never as a legal finding.

The preset maps its tests to GDPR Articles 5, 9, 15, 17 and 22. In plain terms, Article 5 covers the principles of processing such as data minimization, Article 9 covers special category data such as health information, Article 15 covers the right of access, Article 17 covers erasure, and Article 22 covers decisions based solely on automated processing. Ask the team to confirm the exact test-to-article mapping in the promptfoo GDPR documentation for the version you run, because the mapping is the basis for how you describe coverage to reviewers.

Several obligations sit outside testing entirely. Lawful basis and purpose limitation are decisions you document before the feature is built. A data protection impact assessment is a process with stakeholders and a documented outcome. Processor contracts under Article 28, transfers to third countries under Chapter V, and breach notification under Articles 33 and 34 are governance and legal work. Record each of these as a separate control owned by a named person, and cite the promptfoo results only as supporting technical evidence for the controls that a probe can reach.

Mapping GDPR articles to promptfoo gdpr preset tests and configuration

This table links each GDPR article the gdpr preset references to the test area it exercises and the setup that test needs. Read it as a planning map: the articles name the obligation, the test area names what the preset probes, and the configuration column shows what your team must prepare before a run produces useful results.

Article or areaTest area in the presetConfiguration to prepareWhat to confirm before relying on results
Article 5 (principles)Personal data exposure in model outputs and responsesTarget app connected to realistic but synthetic personal data, grading rules that flag identifiers in repliesWhich probes map to Article 5 and how grading treats partial disclosure
Article 9 (special category data)Exposure of health, biometric or other special category dataSynthetic special category samples in the target's context, explicit grader criteria for sensitive categoriesWhether the current preset includes Article 9 probes and their scope
Article 15 (right of access)Access control: whether one user can retrieve another user's data through the applicationTwo or more test identities with different permissions, target configured with the authorization model you actually runHow cross-user access attempts are generated and graded in the current docs
Article 17 (right to erasure)Deletion flows: whether data remains retrievable after a deletion requestTest records seeded, a documented deletion request sequence, and a check that retrieval happens after deletionWhether deletion is tested end to end or only through conversational requests
Article 22 (automated decisions)Automated decision handling for decisions with legal or similar effectScenarios describing consequential decisions, clear expectations for human review or explanation in gradingWhich decision types are covered and how the grader judges adequate human involvement
Article 32 (security of processing)Related obligation: results can inform security findings, but the preset does not cover it fullyUse findings as input to your security of processing review alongside infrastructure and key management controlsDo not treat preset results as evidence of Article 32 compliance

Running the gdpr preset against an AI application

This sequence takes you from a clean install of promptfoo to a reviewed set of GDPR-mapped findings for one AI application. The output is a scan record and a list of failed probes that your privacy and security reviewers can triage, not a compliance determination.

  1. Install promptfoo on a controlled workstation

    An engineer installs promptfoo from npm on a machine that the security team controls. promptfoo is released under the MIT license, and the npm release 0.124.1 requires Node.js 22.22.0 or newer, so confirm your Node.js version before installing. The step is done when the CLI reports its version and runs without errors on that machine.

  2. Prepare a test environment and synthetic data

    Agree with the privacy owner which application, model endpoint and data sources the scan may touch. Load synthetic or approved test records into the target system instead of live personal data, so that any leaked output contains no real individual's information. The step is done when the privacy owner has signed off on the test dataset and the environment is isolated from production.

  3. Point the red team configuration at the target

    Create a red team configuration file that identifies the application or model endpoint under test and the credentials it needs, using the target and provider settings in the promptfoo documentation. Store API keys in environment variables rather than in the file. Confirm the exact configuration keys against the current red teaming documentation for your promptfoo version before relying on them. The step is done when a test request to the target succeeds from the scanning machine.

  4. Select the gdpr preset

    Add the GDPR preset to the red team plugins so that the scan runs probes mapped to GDPR Articles 5, 9, 15, 17 and 22. Review the list of generated plugins and confirm that the scope matches what you intend to test, such as personal data exposure, access control and deletion handling. The step is done when the configuration lists the gdpr preset and the chosen test count is recorded.

  5. Run the scan and capture results

    Run the red team scan from the CLI and save the output to a file so that the run can be reproduced later. Community edition includes red teaming with 10k probes per month, so record how many probes the run used against that allowance. The step is done when the run completes and the results file is stored with the configuration and promptfoo version used.

  6. Review grading and failed probes

    A privacy or security engineer reviews each failed probe to confirm whether the grader was right, checking the prompt, the response and the data involved. Separate true exposures from false positives, and note which findings relate to access control or deletion flows. The step is done when every failure has a recorded disposition and an owner for remediation.

  7. Hand findings to privacy counsel

    Send the confirmed findings, the configuration and the scan record to the privacy owner and counsel. promptfoo states that the gdpr preset is for technical testing and risk discovery and does not certify legal compliance or replace privacy counsel, so legal assessment of each finding stays with them. The step is done when counsel has accepted the findings for assessment and the remediation tickets are open.

What the gdpr preset run produces as evidence

A promptfoo gdpr preset run leaves several artifacts that can be stored and reviewed later. Together they show what was tested, against which model and configuration, and what the findings were, which gives a privacy team a documented starting point. None of them is an audit report or a statement of legal compliance.

Run configuration files

The promptfoo configuration file records the target application, the provider under test, the red team section and the gdpr preset selection. Store it in the same repository as the application so each scan can be traced to the exact setup that produced it. Check that the file holds no live API keys, since keys belong in environment variables or a secrets manager. Reviewers can then see which configuration produced each result set.

Preset and plugin selection record

Record the gdpr preset and the exact plugin set that ran, not only the preset name. Presets can change between promptfoo releases, so note the promptfoo version used, which is the npm package release. A reviewer should be able to tell which GDPR-mapped tests were included and which were excluded or customized. Without this record, two runs labeled gdpr may not be comparable.

Timestamps and tested versions

Keep the run date and time, the model name and version reported by the provider, and the endpoint or application build under test. A model update or a prompt change after the run makes earlier findings stale for that version. Record these fields in the report header or a sidecar file so they travel with the results. Ask your vendor or provider to confirm how model versions are identified in their API responses.

Pass and fail findings by test area

The result report lists each test with a pass or fail outcome, grouped by the GDPR-mapped areas such as data minimization, personal data exposure, access control and erasure handling. Export the report in the format your team reviews, and keep a copy with the run record. Treat each failure as a risk discovery that needs a documented decision, not as a finding of legal breach. Note any tests that errored, since an error is not a pass.

Scope and test data documentation

Write down what the scan covered: which features, data stores, user roles and tool integrations were in scope, and what synthetic or sampled data was used to probe them. A scope statement that names what was excluded is as important as the findings, because a privacy assessment will ask what was not tested. Confirm with your data protection officer that the test data contained no real personal data, or that its handling was approved.

Remediation and retest records

For each failed test, record the fix, the owner, the change reference and the retest result that followed. Keep the original failing report alongside the retest so the sequence is visible. These records show that findings led to action, which a privacy assessment can review, but they do not establish that the system is compliant. Store everything under version control with access limited to the team that owns the system.

Community CLI or self-hosted server for GDPR testing records

The Community CLI is the simplest setup for GDPR testing. Evals and red team runs execute on the machine where you start them, and promptfoo talks directly with the model or application under test. Nothing is sent to a promptfoo-hosted service during that flow, so the people who can read the results are the people who can read files on that machine or in the repository or pipeline where output is written. The Community edition is free and includes LLM evaluation features, all model providers and integrations, and red teaming with 10k probes per month, with community support.

  • Results sit in local output: Test outputs, including any personal data that appears in prompts or responses, are written where the run executes, so file permissions and disk encryption become your main access controls.
  • Access follows the host: Anyone with access to the workstation or CI runner that produced results can read them, so decide which runners and folders are approved for personal-data test sets.
  • No built-in multi-user access: The CLI does not give you per-person roles, so sharing results means sharing files, which should go through controlled storage.
  • Pipeline artifacts need handling rules: When results are published as CI artifacts, retention and visibility settings in the pipeline define who can read them.
  • Suitable for controlled, single-operator testing: A small team working on approved machines with synthetic or pseudonymized test data fits this model well.

Before you start, confirm with promptfoo which capabilities apply to your installed version and whether your test data can include personal data at all.

What GDPR testing with promptfoo does not cover

A promptfoo gdpr preset run finds technical symptoms such as personal data in outputs, weak access checks and deletion paths that do not work. The GDPR obligations below sit outside what an automated probe can prove, so each one needs its own records, contracts, decisions or external review.

Lawful basis and consent records

A passing test does not show that the processing has a documented lawful basis under the GDPR, or that consent was collected and can be withdrawn where it is the basis. Probes can show that a model reveals personal data, but they cannot show why the data was collected in the first place. Ask the privacy team to produce a record of processing for each AI feature, listing purpose, basis, data categories and retention, and confirm that the prompts, logs and training uses named in it match what the tests exercised.

Article 35 DPIAs

A data protection impact assessment under Article 35 is a documented judgment about risk to individuals, made by the controller. promptfoo results can feed that assessment as evidence of exposure found during testing, but they cannot decide whether the residual risk is acceptable. Confirm who signs the DPIA, when it is revisited after model or prompt changes, and whether the test findings are recorded against the risks it identifies.

Processor and sub-processor contracts

Article 28 contracts with model providers, hosting vendors and tool operators set out what each party may do with personal data. A red team run cannot read those terms. Check that every provider receiving prompts or retrieved records has a signed processing agreement, that sub-processor lists are current, and that the endpoints promptfoo tests are the ones covered by those agreements.

Chapter V transfer mechanisms

Chapter V governs transfers of personal data to third countries and requires a valid transfer mechanism for each. Whether a US-hosted model qualifies depends on the transfer basis in use, such as the EU-US Data Privacy Framework adequacy decision (Commission Implementing Decision (EU) 2023/1795) or contractual safeguards. Testing shows where data goes at runtime, not whether the basis is valid. Map each model endpoint to its transfer mechanism and review it when the provider changes regions.

EU-US DPF decision

Article 33 and 34 breach processes

Articles 33 and 34 require the controller to notify supervisory authorities and, in some cases, affected individuals after a personal data breach. Finding an exposure in a test does not start that clock or prove the response works. Confirm that your incident process classifies AI-specific events, such as a prompt that leaked records, that on-call staff know who decides notification, and that the response is rehearsed.

Retention policy and deletion evidence

A deletion probe can show that a record is not returned after a request, but it does not set how long prompts, traces, vector entries or evaluation outputs may be kept. Retention periods are a policy decision tied to purpose. Decide retention for each store, including promptfoo result files and CI artifacts, and confirm that deletion covers backups and derived indexes, not just the primary database.

No audit, certificate or legal sign-off

The GDPR requires no audit, attestation or certificate. Article 42 certification is voluntary, is issued for at most three years by accredited bodies or supervisory authorities, and does not reduce controller or processor responsibility. Regulation (EU) 2025/2518 applies cross-border procedural rules from 2 April 2027, and the Omnibus proposals remain pending, while the GDPR text was not amended as of October 2026. Track these changes with privacy counsel, and treat a clean preset run as one input, not a compliance result.

GDPR text

Questions buyers ask about GDPR testing with promptfoo

What does it cost to run the promptfoo GDPR preset?

The software itself is free to run under the MIT license, and the promptfoo Community edition is free and includes red teaming with 10k probes per month, with community support. Your costs come from the people and time involved, the model API usage your test runs generate, and the infrastructure where you run it. Enterprise adds team sharing, SSO, role-based access control, continuous monitoring and priority support with SLAs, and is sold at custom pricing, so ask promptfoo for a quote. For a services engagement, the quote follows from a written scope that covers the systems in scope, the number of scans and the remediation support you want.

How long does a first GDPR scan and remediation cycle take?

It depends on how many AI systems are in scope, how many data sources and user roles each one touches, and how many findings need fixes by engineering or privacy owners. No duration has been established for this preset, so do not plan from a generic number. Running the scan itself is usually the shortest step. Time goes into agreeing test data, configuring access to each target, triaging findings, deciding which are real exposures, fixing them and retesting. Ask for a timeline in the written scope that lists each stage and who owns it.

Can our internal team run the gdpr preset without outside help?

Yes, if you have engineers who can install the CLI, write a configuration for your application, and read the output. The CLI runs on your own machine and talks directly to the model under test, which keeps setup simple for a single team. The harder parts are scoping the test to real data flows, designing realistic test identities and deletion scenarios, and interpreting findings against your processing records. Teams often keep the scan in their own hands and bring in a partner for scope design, fixes across several systems or a retest after remediation.

What do we need to provide for a GDPR testing engagement?

Expect to supply test accounts with the same roles your real users have, access to a non-production copy of the system or a staging endpoint, and documentation of what data the AI feature retrieves, stores and logs. You will also need named owners from privacy, security and the product team who can approve scope, confirm which findings are in fact exposures and sign off fixes. Ask whether test data can be synthetic, because using production personal data for testing creates its own processing question that your privacy team should decide before any scan starts.

Do promptfoo GDPR test results satisfy a regulator?

No. The preset maps tests to GDPR articles, including Articles 5, 9, 15, 17 and 22, but promptfoo states it is for technical testing and risk discovery and does not certify legal compliance or replace privacy counsel. The GDPR requires no audit, attestation or certificate. Article 42 certification is voluntary and is issued by accredited bodies or supervisory authorities, and it does not reduce the responsibility of the controller or processor. Regulators assess your lawful basis, transparency, retention, processor contracts and transfers, which automated probes cannot judge. Use the output as one input to your own compliance file.

When should we bring in outside help for GDPR testing?

Bring in outside help when the AI system touches several personal data stores, when it has agents or tools that act on user data, when deletion or access requests must propagate across systems, or when your internal team lacks time to triage findings. A partner can also help when a customer security review asks for test evidence. DeployOpen plans and runs security testing for AI systems and prepares the evidence customers ask for, but it does not issue audit reports, attestations or certifications. Ask for a written scope before work starts, including the retest step.

How DeployOpen prepares GDPR test evidence for AI systems

DeployOpen plans, builds and documents promptfoo data protection testing for GDPR inside the infrastructure you control. The work produces technical test results and documentation for your privacy and security teams, while legal conclusions remain with your privacy counsel and any assessor you engage.

How we scope

  • Engagements are fixed-scope, with the systems, data flows and promptfoo gdpr preset tests agreed in writing before work starts.
  • The written scope names which AI applications, retrieval sources and deletion paths are in test, and which are excluded.
  • Scope also records who receives findings and which GDPR articles your privacy team wants the results mapped against.

How we build

  • Promptfoo runs against your own model endpoints and applications, configured so test traffic stays inside your environment.
  • Self-hosted promptfoo is deployed with the persistence, authentication and access controls your scope requires, since its default setup has no built-in SSO or RBAC.
  • Test runs cover personal data exposure, access-control behavior and deletion flows, with fixes for each confirmed finding.

How we hand over

  • Deliverables include the configuration, run records and a findings report that states what was tested and what was not.
  • Each finding is tied to the affected system, the GDPR article it maps to and a recommended remediation for your engineering team.
  • Documentation states clearly that the results are technical testing evidence and not a legal compliance determination.

How we support

  • After handover, your team can rerun the preset after changes, and we can retest fixed findings where the written scope includes it.
  • Ongoing support, upgrades and continuous testing are available as a retainer, scoped separately from the initial engagement.
  • Ask us to confirm which promptfoo features your chosen edition includes before you plan multi-team or centralized use.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.