DevTools Logo

HAR Redactor

HAR Redactor

Strip cookies, tokens, bodies and internal hosts from a HAR before you share it. Nothing is uploaded.

Runs in your browser

Headers & cookies

11

Exact names, case-insensitive; trailing * is a wildcard.

cookieset-cookieauthorizationproxy-authorizationwww-authenticateapi-keyx-api-keyx-auth-tokenx-csrf-tokenx-session-idprivate-token

Query, URLs & bodies

21

Removed from URLs, queryString[] and form bodies together.

tokenkeysecretpasswordpasscodeapi_keyapikeyaccess_tokenrefresh_tokenauthauthorizationsigsignaturecodecsrfxsrfsessioncookieotpprivate_keyclient_secret

Hostnames & advanced

0

Keep only these hosts; *.example.com also matches example.com.

Empty — using defaults
0

Matching entries are removed from the output.

Empty — using defaults
0

Non-standard HAR extensions, e.g. /_securityState or request.headers[].value.

Empty — using defaults
Try an example

HAR input

Sanitized HAR

Paste or upload a HAR to redact it

Cookies, tokens, bodies and host filters are applied in your browser. No capture is saved or uploaded.

Details

A raw HTTP Archive contains the exact things you should not attach to a public ticket: session cookies, bearer tokens, signed query parameters, customer PII and internal hostnames. This tool walks the HAR structure, redacts known-sensitive fields, optionally drops entire hosts, and then scans the serialized result for anything a deny-list might have missed. Timings, statuses, sizes and the rest of the HAR skeleton stay intact so vendor support tools can still open the file. The capture never leaves your browser tab, and only redaction profiles (names and modes, never captured values) can be saved locally.

More examples

Before sharing with SaaS support

Authorization: Bearer eyJ…
Cookie: session=s%3Alive…
→ Authorization: «redacted»
→ Cookie: «redacted»

Headers are replaced wholesale, including Set-Cookie values that contain commas in Expires attributes.

Signed query parameters

GET /v1/orders?token=abcd&api_key=xyz&page=2
→ GET /v1/orders?page=2

Secret parameters are removed from request.url, queryString[] and form-encoded postData.text together, while page stays.

Internal host removal

Deny hosts: internal.corp
Entries in: 48 · Entries out: 31 · Hosts dropped: 17

Host filters run first; dropped entries are never processed or written to the output HAR.

Keep bodies, hide passwords

{"password":"hunter2","keyword":"shoes","accessToken":"abc"}
→ {"password":"«redacted»","keyword":"shoes","accessToken":"«redacted»"}

JSON bodies keep their shape and benign fields so a reproduction still works. Field names are matched as words, so 'keyword' and 'author' survive.

    Examples

    Bearer token and cookie

    Input
    Authorization: Bearer abcdef1234567890
    Cookie: session=LIVE_SESSION
    Output
    Authorization: «redacted»
    Cookie: «redacted»

    Header names are matched case-insensitively; the entire value is replaced, including comma-bearing Set-Cookie values.

    Signed query string

    Input
    GET /v1/orders?token=abc123&api_key=xyz&page=2
    Output
    GET /v1/orders?page=2

    Deny-listed parameters disappear while unrelated parameters keep their original raw encoding.

    JSON body with a benign lookalike

    Input
    {"password":"hunter2","keyword":"shoes","accessToken":"t-123"}
    Output
    {"password":"«redacted»","keyword":"shoes","accessToken":"«redacted»"}

    Field names are matched as whole words: keyword, author, passenger and hotkey are not treated as secrets.

    Hash mode for correlation

    Input
    Cookie: sid=SAME (repeated in 3 entries)
    Output
    Cookie: «redacted:1f2a3b» in all 3 entries; a different value gets a different suffix.

    The suffix is the first six hex characters of a salted SHA-256 digest. Add a salt to stop offline guessing of short secrets.

    About this tool

    A HAR file is a recording of everything your browser sent and received: request and response headers, cookies, query strings, bodies, timings and sizes. That is exactly what a support engineer needs to reproduce a failure — and exactly what you should not attach to a public ticket while it still contains session cookies, bearer tokens or customer email addresses. This tool redacts the sensitive parts in your own browser and leaves the rest of the capture readable by HAR viewers.

    Redaction is structure-aware rather than a text search. Every entry is visited in turn; request and response headers, the standard cookies[] arrays, URL query parameters, form bodies, JSON bodies, response content and custom JSON-pointer paths are handled separately. Names are matched case-insensitively with wildcard support, and values can be replaced with a fixed marker, removed, or replaced with a short deterministic fingerprint so you can still tell repeated values apart without seeing them.

    Host filters run before anything else. An allow-list keeps only the hosts you name (with dot-anchored suffix globs such as *.mycompany.com), while a deny-list removes matching entries entirely — useful for stripping a staging or internal host from a customer-facing capture. Dropped entries never reach the output file, and the summary tells you how many were removed.

    A post-pass then scans the serialized result for patterns a deny-list may have missed: bearer and basic credentials, JWT/JWE prefixes, AWS signature markers, long hex or base64 blobs, and optionally email addresses and IPv4 addresses. Findings are reported per entry with a pattern name and length — never the secret itself — so you can review before sharing. The HAR payload is never uploaded or persisted; only named redaction profiles can be saved in localStorage.

    What this tool does not do

    • Redaction is only as complete as the configured deny-lists and custom paths; the residual scan is a backstop, not a guarantee that every possible secret was found.
    • The JSON parse/stringify round-trip normalizes whitespace, escape styles and number literals; the output is structurally valid HAR, not a byte-identical copy.
    • Files larger than 200 MB are rejected. Parsing happens on the main thread, so very large but accepted captures can briefly freeze the tab.
    • Base64 response bodies are scanned for credential patterns only; binary payloads are not decoded or structurally rewritten.
    • Hash placeholders use a truncated digest: they are for correlation, not secrecy. Set a salt and never treat the suffix as a secret.
    • Host filters require absolute URLs for reliable matching; relative URLs are token-stripped with a regex fallback but cannot be allow-listed.
    • No capture data is uploaded or persisted, but a saved profile contains your deny-list names and regexes; do not put actual secret values in those fields.

    How to use this tool

    1. Load a HAR

      Drop a .har file onto the upload control, choose it with the file picker, or paste the JSON directly. The input panel shows line count and size; captures over 200 MB are rejected with advice to split them.

    2. Choose replacement modes

      Pick a fixed placeholder, a hash placeholder for correlating repeated values, or complete removal for headers, cookie arrays and body fields. Bodies can additionally be kept unchanged or removed entirely.

    3. Edit the deny-lists

      Add exact or wildcard header names, secret query parameter names, custom JSON pointers and host allow/deny patterns. Press Enter in a chip field to add a value and use its remove button to take it back out.

    4. Review the output

      The summary counts entries in and out, hosts dropped and fields touched per category. The residual scan table lists any remaining credential-shaped patterns by entry index; fix the settings and the result re-runs from the original input.

    5. Download and verify

      Download the file as <name>.redacted.har, or copy the JSON and the text report. For a final check, paste the sanitized file back into the input and confirm the scan reports no findings.

    Use cases

    Escalate a customer HAR to a vendor

    Remove the customer's cookies, auth headers and PII before attaching the capture to a support ticket, while keeping timings and status codes the vendor needs.

    Attach a reproduction to a public issue

    Strip signed URLs, internal hostnames and response bodies that echo personal data, then re-upload the sanitized file to confirm a clean residual scan.

    Share a capture under NDA

    Allow-list the hosts a partner needs to see, drop everything else, and keep hash fingerprints so repeated IDs can still be correlated.

    What the redactor touches

    HAR locationBehavior
    request.headers[] / response.headers[]Names matched against the deny-list and regex; values replaced or headers removed. Set-Cookie values are replaced whole, so commas in Expires are safe.
    request.cookies[] / response.cookies[]Standard HAR cookie objects keep their names and metadata; only value is rewritten.
    request.urlUserinfo is stripped, secret query parameters are removed without re-encoding the survivors, and an optional path regex redacts matching path segments.
    request.queryString[] / postData.params[]Parameter values are redacted or dropped using the same name list as URLs; counts are reported per occurrence.
    postData.textForm-encoded bodies are rewritten in lockstep with params[] so a token cannot survive in the raw text; JSON bodies are walked field by field.
    response.content.textJSON bodies are redacted recursively; other text and base64 bodies are scanned for credential patterns. content.size is updated when the text changes.
    Custom JSON pointersPaths such as /_securityState or request.headers[].value reach non-standard browser extensions; * and [] wildcards are supported.
    log._redactionOptional per-entry change lists and log-level counts for auditing what was modified.

    HAR 1.1, 1.2 and browser-specific underscore extensions all parse. Unknown keys pass through untouched unless a custom pointer matches them.

    Common mistakes

    Mistake:Searching the HAR text for 'token' and deleting the matching lines.

    Fix:A text search misses cookie arrays, response bodies and URL userinfo, and can damage valid JSON. The redactor walks the structure and updates the fields HAR consumers actually read.

    Mistake:Redacting postData.params[] but leaving the raw form-encoded body untouched.

    Fix:Browser exports duplicate form parameters in postData.text. This tool rewrites both from the same name list, so a stripped token cannot survive in the raw text.

    Mistake:Assuming a short hash suffix is safe against guessing.

    Fix:A six-character digest of a low-entropy secret can be brute-forced. Use hash mode for correlation only, and set a hash salt that is not shared with the recipient.

    Mistake:Using a broad /pass|auth|key/i body pattern and wondering why the reproduction stopped working.

    Fix:Whole-word matching keeps keyword, author and passenger intact. Add specific custom field names or a body field regex if your API uses an unusual name.

    Mistake:Expecting a byte-for-byte copy of the original file.

    Fix:JSON.parse/JSON.stringify normalizes whitespace and escape styles, and sizes of changed headers or bodies are recalculated. The HAR stays structurally valid, not textually identical.

    Mistake:Sharing the file immediately after a residual finding was reported.

    Fix:Findings are a warning, not a pass. Adjust the deny-lists or custom paths and re-run against the pristine input until the scan is clean, or accept the risk explicitly.

    Frequently asked questions

    What does a HAR file contain that is sensitive?

    A HAR records request and response headers (including Cookie, Set-Cookie and Authorization), cookie arrays, query strings with signed tokens, POST and response bodies that may echo passwords or customer records, and internal hostnames. Even a harmless-looking capture can contain a live session that lets someone act as the user who recorded it.

    Does redacting a HAR break it for support tools?

    No. The tool keeps the HAR structure intact: entries, timings, statuses, sizes and custom keys remain in place, and only sensitive values are rewritten. It is a JSON parse/stringify round-trip, so whitespace and escape styles may change, but any HAR viewer or vendor upload endpoint can still open the result. Sizes of changed headers and bodies are recalculated instead of being left stale.

    Can I keep POST bodies but hide passwords?

    Yes. The default body mode walks JSON bodies field by field and replaces values whose names are whole-word matches for password, token, secret, auth, cookie, session and similar terms. Benign lookalikes such as keyword, author, passenger and hotkey are preserved, so the reproduction still makes sense. Form-encoded bodies are rewritten in lockstep with postData.params[], so a token cannot survive in the raw text.

    How do I remove a whole host from a HAR?

    Add it to the Deny hosts chip list, for example internal.corp, or put a suffix glob such as *.staging.example in the Allow hosts list to keep only those hosts. Matching entries are removed before any other redaction happens, and the summary reports how many were dropped. Globs are dot-anchored: *.corp.example matches corp.example and api.corp.example, but not notcorp.example.

    Is my HAR uploaded anywhere?

    No. Parsing, redaction, host filtering and the residual scan all run in this browser tab. There is no network request and no localStorage entry for the capture; the download uses a temporary object URL. You can optionally save a redaction profile, which stores only the field names, regexes and modes you chose — never captured values.

    What does the residual secret scan actually check?

    After redaction, each entry and the log-level fields are scanned separately for bearer and basic credentials, JWT/JWE-style prefixes, AWS signature markers, long hex or base64 blobs, and optionally email addresses and IPv4 addresses. Findings show the entry index, pattern name, occurrence count and value length — not the value itself — so you can find and fix a miss without exposing it in the report.

    Why would I choose hash placeholders over a fixed marker?

    Hash mode replaces a value with «redacted:» followed by six hex characters of a SHA-256 digest. The same input produces the same suffix, so you can still see that 30 entries used one token without seeing the token. It is correlation, not encryption: set a hash salt that you do not share with the recipient, and avoid relying on it for low-entropy secrets.

    Can I redact a non-standard field added by a browser extension?

    Yes. Add a JSON pointer under Custom JSON pointers, such as /_securityState, /_webSocketMessages or request.headers[].value. Wildcards * and [] are supported, and a matching string value is rewritten with the field replacement mode you selected. Unknown fields without a matching pointer pass through untouched.

    Why does the output not look byte-for-byte like my original file?

    The tool parses the HAR as JSON and serializes it with stable indentation. That normalizes whitespace, number literals and escape styles, and it updates headersSize, bodySize and content.size when a value shrinks. The content and structure are preserved, but the exact bytes are not — which is why the acceptance check is a valid HAR with no planted secrets, not a string diff.

    What happens with very large HAR files?

    Files over 30 MB show a warning because parsing can briefly freeze the tab, and files over 200 MB are rejected before reading with advice to split the capture into smaller HARs. There is no streaming JSON parser, so a 150 MB file still needs enough memory for the parsed object and the serialized output.

    References & standards