Block a header bidding script on websites to isolate testing of other scripts.

Kanishk Rawat
Block header bidding scripts for isolated script testing and efficient debugging using Requestly’s Cancel Rule, ensuring accurate results in a live environment.
Block-Header

Introduction

Header bidding scripts increase ad revenue, but they can get in the way when testing other ad scripts. For example, when you’re working on testing new ad placements or tracking scripts, header bidding can interfere with results, making it hard to see what’s happening.

With Requestly, you can block these header bidding scripts and isolate your tests, making it easier to focus on the other ad scripts you want to evaluate without any confusion.

The Problem

When you run tests with other ad scripts while header bidding is active, the results can be skewed. Header bidding adds extra complexity to the page, making it harder to see how your other scripts are performing

Existing Solutions

Currently, ad tech teams use two common approaches:

  1. Test Environments: Set up a separate site where header bidding is disabled for testing.
  2. Manual Removal: Edit the client’s site code manually to remove header bidding scripts before testing.

Both methods work, but they can be slow.

Challenges with These Solutions

These approaches often have the following issues:

  • Takes Too Long: Setting up separate test sites or manually removing scripts can take days.
  • Requires Developers: You often need a developer to remove or disable the scripts, which slows things down.

Block a header bidding scripts

The Cancel Rule in Requestly allows you to effortlessly block header bidding scripts on client websites, enabling isolated testing of other scripts. This is perfect for debugging and evaluating different configurations without interference from header bidding scripts, providing accurate insights into performance without altering the client’s production environment.
Block Header bidding

  • Source Condition: This is where you decide which requests to Block or cancel. In the example, any request that contains example.com/header-bidding.js in the URL will be affected.
  • Test URL Condition: You can check if the rules you’ve set up work correctly by testing them on specific URLs.
  • Filter Out Condition: You can apply filters to limit which requests are affected, making sure only the ones you want are modified.

Or create your own Rule by following the steps below

Here’s how to set up a rule to block header bidding scripts for isolated testing using Requestly’s Cancel Rule:
  1. Open Requestly: Open Requestly app.
  2. Create a New Rule: Click on New Rule and select the Cancel Request option.
  3. Define the URL Pattern: Enter the URL pattern of the header bidding script you want to block.
  4. Apply the Rule: Save the rule to block the specified header bidding script on the website.

Interactive Guide

Check this interactive and easy explanation of how to use Cancel Request Rule

Conclusion

Try this Cancel Rule to block header bidding scripts and test other scripts on production without affecting the live environment. This approach allows you to isolate and evaluate specific scripts without interference from header bidding, ensuring accurate testing. Requestly is trusted by over 200k developers and 1000+ companies for seamless network request management.

Explore More:

Kanishk Rawat
Kanishk Rawat, a tech enthusiast since childhood, has mastered programming through dedication. Whether solo or in a team, he thrives on challenges, crafting innovative solutions .

Contents​

Subscribe for latest updates​

Share this article

Related posts