HAR Sanitizer
Remove cookies, tokens, passwords and other secrets from a HAR file before you share it. See what was found, choose what to remove, and download a clean copy. Everything runs in your browser.
What to remove
More options
With numbered marks, the same value gets the same number everywhere, so you can still see which requests used the same token.
Put each item on its own line. It is replaced everywhere it appears, also inside web addresses.
Separate names with commas. Headers, cookies, URL parameters and form or JSON fields with these names are removed.
🔒 Your HAR file is read in your browser. It is never uploaded or saved anywhere.
Clean a HAR file before you share it
This free HAR sanitizer removes cookies, session tokens, Authorization headers, passwords, API keys, JSON Web Tokens, email addresses and card numbers from a HAR file. Open the file and the tool shows every secret it found, grouped by kind and by name, with the requests each one appears in. Uncheck anything you want to keep, then download a clean copy that is still a valid HAR file. Everything runs in your browser, so the file is never uploaded.
Why a HAR file needs cleaning
A HAR file records everything a page sent and received while it was saved. That makes it the best way to show a support team or a developer what went wrong, but it also means the file holds whatever was in that traffic:
- Session cookies, which can let someone act as you on the site until the session ends.
- Authorization headers with Bearer tokens or a Basic password.
- Access and refresh tokens in login responses, often as JSON Web Tokens.
- Passwords and card details in the forms you filled in.
- API keys and one-time codes in web addresses and query strings.
- Email addresses and other personal details in headers and bodies.
Anyone who has the file can read all of this, so clean it before you attach it to a ticket or a chat.
How to sanitize a HAR file
- Drop the HAR file on the box, click it to choose a file, or click Paste HAR text. To see how it works first, click Try a sample.
- Read the summary: how many sensitive values were found, in how many places and in how many requests.
- Look through What to remove. Everything is checked except IP addresses. Uncheck a value to keep it, or uncheck a whole group, such as Cookies, at once.
- Click Where next to a value to see each request and part of the request it was found in.
- Click Download sanitized HAR to save the clean file. Copy puts the text on the clipboard, and Preview shows it.
The clean file is made again each time you change a setting, so the download always matches what you see.
What the HAR sanitizer finds
- Cookies: the values in Cookie and Set-Cookie headers and in the cookie lists of each request and response. The cookie names stay, so you can still see which cookies were sent.
- Authorization headers: the credentials after Bearer, Basic and other schemes. The scheme name stays.
- Secret headers: headers whose names show they carry a key or token, such as
x-api-keyandx-csrf-token. - Secrets in addresses: tokens, keys, session IDs, login codes and passwords in URLs, query strings, redirect addresses and the
user:password@part of an address. - Passwords and form data: password, token and card code fields in form posts, JSON request bodies and file uploads.
- Tokens in responses: access tokens, refresh tokens, CSRF tokens and similar fields in JSON, in HTML forms and meta tags, and in settings written into scripts.
- JSON Web Tokens: any value that has the shape of a JWT, wherever it is in the file.
- Keys in known formats: API keys and private keys with a recognizable format, even in a field with an ordinary name.
- Email addresses anywhere in the file, including URL-encoded ones.
- Card numbers that pass the card number check (the Luhn check), so order numbers and other long numbers stay.
- IP addresses: off at first, because they often help to find a network problem. Check them to replace them too.
Field names are matched in a smart way: password, api_key and sessionToken are replaced, while fields that only describe a secret, such as token_type, expires_in or password_hint, are kept.
The same value, the same mark
Each secret is replaced with a numbered mark such as [REDACTED-3]. The same value gets the same number everywhere in the file, so whoever reads it can still see that two requests used the same session or the same token. If you prefer, choose The same mark: [REDACTED] under Replace each secret with.
Only the values change. Header names, cookie names, URLs, timings and status codes stay as they were, so the clean file opens in any HAR viewer and still shows the problem you want to share. The file keeps its original indentation too.
Checked again after cleaning
After it builds the clean file, the tool scans it a second time. A green line says when none of the selected kinds of secrets are left. If anything is left, it says what, so you can turn on more options before you share the file.
More options
- Remove response bodies deletes the content of every response, for when the pages themselves contain private data. Remove request bodies does the same for what was sent.
- Also remove this text replaces any text you type, such as a name, a customer number or a street address, everywhere it appears, also inside web addresses. Put each item on its own line.
- More field names to remove treats the names you type as secret, for fields only your site uses, such as
customer_id.
Look at the result
Open the clean file in the HAR Viewer to check the requests, headers and timings before you send it. To see what a token you found contains, paste it into the JWT Decoder, and if a HAR file won’t open, the JSON Validator shows where the JSON is broken.
What to check yourself
The sanitizer finds secrets by field name and by format. It can’t know that an ordinary field holds something private, so look at the result before you share it:
- Names, addresses and phone numbers in page content are kept, unless they are in a secret field. Add them under Also remove this text.
- Images and other binary responses are not read.
- Secrets in a field with an ordinary name and no known format are kept. Add the field under More field names to remove.
Big HAR files
The file is read and cleaned in the background, so the page stays responsive. In our tests, a 97 MB HAR file with 16,000 requests was cleaned in under 2 seconds on a laptop. Files up to 512 MB can be opened; very big files need a lot of memory, so use a computer rather than a phone for them.
Your HAR file stays private
The HAR sanitizer runs entirely in your browser. Your file is read and cleaned on your device, and it is never uploaded or saved anywhere. Closing the page clears it.
Frequently asked questions
What does a HAR sanitizer do?
It removes secrets from a HAR file, such as cookies, session tokens, Authorization headers, passwords and API keys, and keeps everything else. The result is a HAR file you can share to show a problem without giving away access to your account.
Is this HAR sanitizer free?
Yes. It’s free, with no sign-up and no limit on how many files you clean.
Is my HAR file uploaded?
No. The file is read and cleaned in your browser and never leaves your device.
Will the sanitized file still open in a HAR viewer?
Yes. Only the secret values are replaced, so the file stays valid JSON with the same requests, headers, timings and status codes.
Why are the secrets numbered?
The same value always gets the same number, such as [REDACTED-3]. That way you can still see which requests used the same cookie or token. You can switch to a plain [REDACTED] mark under More options.
Why are IP addresses kept at first?
Server IP addresses often help to find a network or DNS problem, and they are rarely secret. Check IP addresses in the list to replace them too.
Can I keep some values?
Yes. Uncheck any value or a whole group in What to remove, and it stays in the file as it is. The summary tells you how many values you kept.
Does it remove everything private?
It removes secrets it can find by field name or by format. Names, addresses and other details in page content are kept unless you add them under Also remove this text, so look at the result before you share it.
