Content-Disposition Header Explained

What the HTTP Content-Disposition header does and when it's used.

Published October 16, 2026

The Content-Disposition header suggests how a response should be handled, such as displayed inline or downloaded as a file.

Key points

  • "Content-Disposition: attachment; filename=report.pdf" prompts the browser to download the file with that name
More HTTP articles