Skip to content
ScrubLogs

What a OpenAI API key looks like

Current project keys start with sk-proj-, service account keys with sk-svcacct- and admin keys with sk-admin-, followed by a long random string. Older user keys started with sk- and contained the marker T3BlbkFJ.

A fake example, in the right format:

sk-proj-Fak3Demo0nlyKeyF0rScrubLogsSampleText9x8y7z6w5v4u3t2s1r0qPoNmLk

ScrubLogs replaces it with <OPENAI_KEY_1>.

Why a leak is dangerous

Leaked AI keys are resold and used to run large workloads on your bill, often until the account hits its spending limit.

If yours leaked: rotate it

Redacting a copy doesn’t un-leak the original. If the real value was shared anywhere, replace it:

  1. In the OpenAI platform, open API keys and revoke the leaked key.
  2. Create a new key scoped to a single project and deploy it.
  3. Check usage for spikes and set a monthly budget limit.

Remove keys from your own log

Runs 100% in your browser. Nothing is uploaded.

Other secret types