# What Is Data Retention and Zero Data Retention?

> How long AI providers and your own systems keep prompts and answers, what zero data retention really covers, and where copies still sit, for your AI interview.

**In short:** Retention is how long a copy of your data is kept. Zero data retention (ZDR) is an approved arrangement where the provider keeps no prompts or answers after the reply for the features it covers, apart from narrow safety exceptions. Your own copies still need their own limits.

AI and LLM interview question Q464, Data, privacy, ethics and governance. Intermediate, occasional (our estimate). From Venkat R. Murty's free Interview Kit: https://designervenkat.online/interview/ai/data-retention-and-zero-data-retention

## Say it in 30 seconds

Data retention is how long a copy of my data is kept, and by whom. Zero data retention is an approval with a provider: for the features it covers, they keep no prompts or answers once the reply is sent, apart from narrow safety exceptions. It is not automatic. It depends on the feature and sometimes the model. And it only covers their copies, so my own logs, traces and backups still need a set period and a scheduled delete.

## Say it in 2 minutes

When my team sends a claim to an AI model, copies of that claim can end up in several places. The provider may keep a log for abuse checks, and some features keep files or threads until someone deletes them. Our own traces, backups and databases keep copies too. Retention is simply how long each of those copies is kept.

Zero data retention is a setting for eligible features only. For those features it means no prompts or answers are kept after the reply, apart from narrow safety exceptions. But I never take it on trust from a marketing page. OpenAI approves eligible customers, and only some endpoints are covered. Stored files and conversations keep data until deleted, even with it switched on. Anthropic's Legacy ZDR, one of its three data arrangements, has a similar limit: some models need 30 days of retention and are not covered.

So I check the setting against each feature we call, then run one test claim through the system. After that, our own copies become my job. Traces get names masked and a short life. Backups expire on a schedule. The claim record follows the period our policy sets.

Training is a separate question. OpenAI says data sent to its API is not used to train its models unless you opt in, and Anthropic says retained data is never used for training without your express permission. Neither statement stops storage.

## What is data retention, in plain words?

Retention is how long a copy of something is kept before it is deleted. A copy can sit in more than one place, and each place can have its own rule.

Think of a claims firm's file room. Each file is kept for a set time, then shredded on a schedule. Zero data retention is a stronger deal: a print shop that copies your papers agrees to keep nothing once the job is done, and you check that they do.

In AI, a claims agent sends a 12-page medical report to a model. The provider may keep a log of that call, and your own app may keep another copy.

- **Retention:** How long a copy is kept, and where.
- **Zero data retention (ZDR):** An approved deal where the provider keeps no prompts or answers after the reply for eligible features, apart from narrow safety exceptions.
- **Abuse log:** A record a provider keeps of API calls to catch misuse. OpenAI keeps these for up to 30 days by default.
- **Application state:** Data a feature stores to do its job, such as a saved thread or an uploaded file.
- **Trace:** A record your own app writes of each step an agent took, so you can debug it.

## What do the big providers keep by default?

OpenAI keeps abuse monitoring logs of API use by default, for up to 30 days, unless longer retention is required by law, or it is reasonably necessary to protect its services or a third party from harm. Anthropic keeps prompts and outputs by default only for certain models.

> "By default, abuse monitoring logs are generated for all API feature usage and retained for up to 30 days, unless longer retention is required by law, or is reasonably necessary to protect our services or any third party from harm." (OpenAI)
>
> "Conversation content (your prompts and Claude's outputs) is not retained by default; the exception is Covered Models, which require 30-day retention." (Anthropic)

Training is a separate question from storage. OpenAI says data sent to its API is not used to train or improve its models unless you opt in. Anthropic says retained data is never used for training without your express permission. Neither statement stops the storage that remains.

*Diagram, Where one request can leave copies: One request and the copies it can leave with the provider. Zero data retention removes the provider's copies only where the feature is eligible. Your own copies sit outside this picture.*
1. Your code sends the prompt to the model.
2. The provider logs the call for abuse checks, by default for up to 30 days.
3. Some features also store state, such as threads or files, until you delete them.

Take a mid-size insurer that sends about 4,000 claim calls a month, a made-up volume. At 30 days of abuse logs, roughly one month of those calls sits with the provider at any time. The team cannot shrink that number by changing its prompts.

## What does zero data retention really cover?

ZDR is an approval, not a default. OpenAI says eligible customers can be approved for it, and then eligible endpoints do not retain any customer content for application state.

> "Zero Data Retention eligible endpoints do not retain any customer content for application state, subject to the limitations below." (OpenAI)
>
> "Under a Legacy ZDR arrangement, Anthropic does not store customer prompts or responses at rest after the API response is returned." (Anthropic)

Anthropic's page now lists three data arrangements: Legacy ZDR, HIPAA readiness and Enterprise Frontier Safeguards ZDR. The last one is in beta. So I name which one a contract gives me, because the quote above is for Legacy ZDR only.

Two things surprise people. First, it is per feature. On OpenAI's data controls table, the rows for files, conversations and vector stores show data kept until you delete it, and none of them is ZDR eligible. Switching ZDR on does not reach them.

Second, it can depend on the model. Anthropic says some models need 30-day retention and are not available under Legacy ZDR unless Anthropic authorises them.

Third, a safety check can override ZDR. If OpenAI's classifier flags an image or file as possible child abuse material, it is kept for manual review, even with ZDR on. And OpenAI can make a model ineligible for a specific customer if that is needed to prevent severe risk activity.

1. **Get it in writing:** Ask for the approval on the account, and check which level it was set at. OpenAI sets it for the whole organisation or per project.
2. **List the features:** Check each endpoint and model your app calls against the provider's table, not against the headline.
3. **Test one real claim:** Send a test request, then look at what the provider and your own systems store about it.
4. **Own the rest:** The provider's promise ends at its own walls. Your logs, traces and backups need their own rules.

Take a claims-triage agent at a mid-size insurer, a made-up example. The team turns on ZDR, then uploads each 12-page report to the provider's file store so a later step can read it again. Weeks later the reports are still there. Files are kept until deleted, and that endpoint is not ZDR eligible. The fix is to send the report inside the request and delete any upload after use.

> **Tip:** Asked whether your data is retained, don't answer with one word. Name the feature, the account setting and the model, then say what is still kept.

## Where do the copies you control still live?

A provider's promise covers only what it stores. Your side has more copies: traces, caches, a vector index, backups, and exports that a tool saved to a shared drive.

OWASP's 2026 list warns that observability tools such as Langfuse, LangSmith and Datadog log full prompts, completions and traces by default. So a ZDR contract can sit next to a full copy in your own monitoring tool. OWASP's advice is to enforce no-train and no-retain in the technology, not only in policy text.

- **Traces:** Keep the steps for debugging, with names and IDs masked. Make the period short, such as seven days, and write down why.
- **Caches and queues:** A saved answer or a job waiting in a queue is a copy too. Give it an expiry time.
- **Backups:** A backup holds data from before a delete. Its lifetime sets how long deleted data still exists, so plan for it.
- **Vector index:** Text chunks from a claim file are a copy. Remove them when the source file is deleted.

*Diagram, Your own copies, for one claim: Made-up periods for one claim. The provider's copies are a separate question, and zero data retention can cover only those. Each copy on your side needs its own period and its own delete.*
1. The agent reads the report from the claim file.
2. Traces keep the steps for debugging, with names masked.
3. Backups hold the same data until the backup expires.
4. The claim record is kept for the period your policy sets.

### How would you set retention for a claims-triage agent?

Start with a list of every copy, then set one period per kind, not one for the whole system. This is the order I follow.

1. **List every copy:** Provider logs, stored state, traces, caches, backups, the vector index and exports to the claims system.
2. **Give each kind a purpose and a period:** Prompt copies 30 days, traces 7 days, backups 35 days, the claim record as the policy sets. The numbers are made up for this example.
3. **Automate the delete:** A nightly job removes what has expired and writes a line for each thing it removed, so the delete can be checked.
4. **Set the vendor side in writing:** ZDR where the feature is eligible, uploads deleted after use, and a note of which models are not covered.
5. **Test it end to end:** Pick a test claim, follow its copies everywhere, and check the job removes them on time.

The code below is that nightly job in miniature. It uses made-up periods and gives the same output every run.

```python
# A simplified retention sweep for a claims agent's own copies. The periods are made-up numbers for this demo.
from datetime import date

TODAY = date(2026, 11, 27)
KEEP_DAYS = {"prompt_copy": 30, "trace": 7, "claim_file": 2555}

records = [
    ("prompt_copy", "c-1042", date(2026, 10, 20)),
    ("trace", "c-1042", date(2026, 11, 18)),
    ("trace", "c-1077", date(2026, 11, 25)),
    ("claim_file", "c-0931", date(2025, 6, 4)),
    ("claim_file", "c-1042", date(2026, 10, 1)),
]

def expired(kind, made):
    return (TODAY - made).days > KEEP_DAYS[kind]

kept, deleted = [], []
for kind, claim, made in records:
    (deleted if expired(kind, made) else kept).append((kind, claim))

for kind, claim in deleted:
    print("delete", kind, claim)
print("kept", len(kept), "of", len(records))
```

Output:

```text
delete prompt_copy c-1042
delete trace c-1042
kept 3 of 5
```

The rule to say out loud: a delete job is only as good as its list. A copy that is not on the list is never deleted.

## What does the interviewer want to hear?

**A strong answer covers**

- [ ] A plain definition: how long a copy is kept, and by whom.
- [ ] ZDR is an approved arrangement, per feature and sometimes per model.
- [ ] Training and retention are separate settings.
- [ ] The provider's promise covers its copies only, so name your own.
- [ ] A delete job that works from a written list of copies.
- [ ] Honest limits: approval, eligibility, and a test before you trust it.

**Common traps**

- Trap: "Zero data retention means nothing is stored anywhere." Better: It covers the provider's eligible features only. Your logs, backups and file uploads still need their own rules.
- Trap: "Turn it on and we are done." Better: It needs approval, and it can depend on the feature and the model. Test one claim end to end.
- Trap: "The model doesn't train on our data, so retention doesn't matter." Better: Training and storage are separate. A provider can skip training and still keep a log for abuse checks.

## Can you spot the retention gap?

**Spot the gap:** Your team says the claims agent is under zero data retention. Which line keeps a full copy of the claim text on our side?

A. The model call goes to an endpoint marked eligible for ZDR, and nothing about the call is written to our own logs or traces.
B. The tracing tool saves each full prompt for 90 days, in our own account.
C. The reply is shown to the claims clerk, then cleared from the screen.
D. The job logs only the claim ID, the step name and the time taken.

**Answer:** B. The tracing tool sits on our side, so the provider's ZDR never reaches it. A full prompt in a trace is a copy, and it needs a short period with names masked.

**Quick check:** A team turns on ZDR, then uploads claim PDFs to the provider's file store so a later step can reuse them, with no expiry set. What happens to the files?

A. Nothing, because ZDR covers every upload.
B. They stay until someone deletes them, because file storage is not ZDR eligible.
C. They are deleted after 24 hours.
D. The model learns from them, so they are kept for good.

**Answer:** B. On OpenAI's data controls table, the files endpoint keeps data until deleted and is not ZDR eligible. Files can also be set to delete automatically, but that is an explicit setting, not the default. Delete uploads after use, or send the text inside the request.

## Can you answer these from memory?

**Flash cards**

- **What is data retention?** How long a copy of data is kept, and where, before it is deleted.
- **What is zero data retention?** Approved, per feature: no prompts or answers kept after the reply, apart from narrow safety cases.
- **Is ZDR the default?** No. It is approved per account, and covers only eligible endpoints and models.
- **What does OpenAI keep by default?** Abuse monitoring logs of API use, for up to 30 days.
- **Does ZDR cover your own logs?** No. Traces, caches, backups and vector indexes need your own rules.
- **Does training mean retention?** No. Training and storage are separate settings.

## Likely follow-up questions

- Q459 GDPR basics for AI apps? https://designervenkat.online/interview/ai/gdpr-basics-for-ai-apps
- Q463 Auditability and audit logs? https://designervenkat.online/interview/ai/auditability-and-audit-logs
- Q242 How do you log without storing sensitive data? https://designervenkat.online/interview/ai/how-do-you-log-without-storing-sensitive-data
- Q213 What is sensitive information disclosure? https://designervenkat.online/interview/ai/what-is-sensitive-information-disclosure
- Q465 Transparency duties (AI disclosure, deepfake labels)? https://designervenkat.online/interview/ai/transparency-duties-ai-disclosure-deepfake-labels
