
Enable Zero Data Retention in the xAI Console
Turn on team-wide Zero Data Retention (ZDR) from the xAI Console when compliance requires that API prompts and model outputs never land on disk, accepting that stateful Responses history, new Files uploads, Collections, Batch, deferred completions, and hosted Imagine outputs become unavailable while it is active. Official Security FAQ walks team admins through Enable, the confirmation acknowledgments, and how to verify the Active badge plus the x-zero-data-retention response header. For most teams the default 30-day audit retention is the better choice; enable ZDR only when your requirements truly demand it.
What you need
A team-admin login at console.x.ai, the correct team selected in the team picker, and a plan to delete existing Files and Collections first — the Console blocks Enable while stored files or collections remain. Neighboring jobs include Send a safety_identifier on the Grok API for end-user attribution without ZDR, Use the US regional xAI API endpoint when residency routing is the goal instead of ZDR, and Send Imagine video to your upload URL for the output.upload_url path ZDR still requires for video. More API jobs live on the API hub.
Enable ZDR as a team admin
- Sign in to the xAI Console as a team admin and select the team you want to change in the team picker.
- Delete any existing Files and Collections for that team. Enable stays blocked until those stores are empty.
- Open Team Settings, find the Zero Data Retention (ZDR) row, and click Enable.
- Review the acknowledgments in the confirmation dialog, including that deleted User Content cannot be recovered, accept the Enterprise Terms and Privacy Policy, and click Enable to confirm.
Once enabled, ZDR applies to every API key on that team with no per-key toggle and no code change required. To turn it off later, use the same Zero Data Retention row and choose Disable. If you do not see the control, you may not be a team admin, self-serve ZDR may be unavailable in your environment, or a negotiated Enterprise agreement may govern retention — contact sales@x.ai in that case.
Verify it is active
- Team Settings shows an Active badge on the Zero Data Retention row.
- The team picker shows a ZDR badge next to the team name.
- Every API response includes
x-zero-data-retentionset to"true"or"false", so your client can assert the mode programmatically. - Audit logs still show administrative events; API request and response content does not.
Pitfalls
Enabling ZDR clears per-key request-logging flags and blocks new Files and Collections uploads while existing rows can still be viewed and deleted. Stateful previous_response_id history and Batch jobs are unavailable under ZDR, so client-side history plus encrypted content becomes your continuity path for agentic work. Image generation under ZDR is limited to base64 returns on supported Imagine models, and video requires your own output.upload_url.