How to modify HTTP(s) Request & Response Headers in Chrome, Firefox & Safari using Requestly

Modify HTTP(s) Headers using Requestly

HTTP(s) Headers are key-value pairs that can be used by the client or the server to pass additional information along with an HTTP(s) request or response. An HTTP(s) header consists of its case-insensitive name followed by a colon (:), then by its value.

The ability to modify the headers of traffic that passes through your browser is a great tool to have.

You can delete certain headers to minimize online tracking, remove CSP while testing, test sites in production and so on.

Using Requestly, Headers can be added/modified by a simple series of clicks. All you need is to install Requestly extension in your browser.

Modify HTTP Headers could be selected from the options of different rules on the left side of your screen.

Select if you want to modify request header or response header and give a suitable name and description to the rule.

Remove Content-Security-Policy Response Header (Example)

Step 1. Select Header Type — Request Headers or Response Headers

Removing Content Security Policy header on example.com

Step 2. Select Operation — Add/Remove/Modify

You can add a new header or remove, modify an existing request/response header. For this example, we will select Remove.

Removing Content Security Policy header on example.com

Difference between Add and Modify option

Add operation works when a new header is to be added to the request/response whereas modify option modifies an already existing header.

Step 3. URL Targeting — Specify when Modify Headers rule should apply

You can apply the rules based on URL, hostname or path. You can also use regex to match it.

URL Targeting — Apply the Rule when URL Contains example.com

More Examples

If you haven’t installed Requestly yet, please install it to modify request and response headers. Reach out to contact@requestly.io for any questions.

Content from this article is taken from https://docs.requestly.io/using-rules/modify-headers

--

--

--

Setup redirects, modify headers, switch hosts, insert user scripts and much more. Install it on Chrome & Firefox and join our family of more than 100,000 devs!

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Android 2 Din Car Multimedia Player MP5 Player Touch Screen Stereo Bluetooth Car Radio FM MP5…

CS 373 Fall 2021: Gregory Raper Week 9

My beginning of code life.😀

How to do system design for a Movie Ticket Booking System like bookmyshow.com, fandango.com

APPICS Referral Program is now live | Onboard users through your Ref Link and get APX Delegation!

Building a maps platform for the public service

Product Update Issue 9: C-OP Hatching Program Imminent

Engineering Org Design: Code-centric vs. Product Goal-centric Teams

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Requestly

Requestly

Setup redirects, modify headers, switch hosts, insert user scripts and much more. Install it on Chrome & Firefox and join our family of more than 100,000 devs!

More from Medium

Learning Front-end vs Back-end development as a software engineer

Simple code that implement countdown on React.

What the heck is hack?

Well Known Alternatives To NodeOS