Share a useful log excerpt safely

Reduce a log to the relevant event and remove secrets before creating a paste.

Updated 29 Sep 2026

Logs often contain more private information than their authors expect. Before sharing an excerpt, identify the event you want someone to investigate. Keep a short interval around that event and retain timestamps when they help show the sequence. Mention the time zone and application version separately instead of including an entire configuration file. Search the excerpt for authorization headers, cookies, passwords, access tokens and connection strings. Check query parameters and request bodies as well as obvious error messages. Email addresses, customer identifiers and internal hostnames may also need to be removed. Automated pattern matching is not a guarantee that a log is safe; review the remaining text yourself. Replace sensitive values consistently. If the same account appears on several lines, use the same invented label so the relationship between events remains understandable. Keep error codes and structural details that are necessary to diagnose the problem. Do not modify timestamps or ordering without saying that you did so. Choose an appropriate sharing method. An unlisted paste is accessible to anyone who receives its link. Password protection adds an access check but is not end-to-end encryption. Use your organization approved secure channel for information that must not be stored by a paste service. Set an expiration that matches the investigation and send the password separately when one is used. If a real secret was exposed, deleting the paste is not enough: revoke or rotate that secret through the responsible service. Share only the sanitized excerpt, not the original file.
Application: [name and version]
Time zone: [zone]
Observed issue: [short description]

[time] INFO request_id=example-1 action=export
[time] ERROR request_id=example-1 code=EXAMPLE_ERROR

Removed before sharing
- [types of sensitive values removed]

Expected result
[description]

Question
[what needs investigation]