The Replace Rule in Requestly lets you seamlessly load your local RTB script into client websites, facilitating easy testing of RTB setups. This is ideal for evaluating different RTB configurations or versions in a live environment, delivering accurate performance insights without changing the client’s production environment.
Easily Test your Local RTB Scripts on Production Without Deploying
Kanishk Rawat
September 10, 2024
2MIN READ
Discover how to test your local RTB scripts directly on production without deploying. Learn a seamless method to validate ad setups using Requestly.

Your lightweight Client for API debugging
No Login Required
Get Requestly
Requestly Works on Desktop Only
Requestly isnât available for download on mobile or tablets.
To download it, please open this page on a desktop PC and enter your email to get the link.
Mac app
Lightweight & Privacy-first API Client
- Local Projects
- Organize API into Collections & Environments
- API Tests
- Import from Postman, OpenAPI, etc
Download Now
Chrome extension
Intercept & modify HTTP requests/responses
- Redirect URLs & modify HTTP headers
- Mock API / GraphQL responses
- Insert custom JavaScript scripts
Add To Chrome
Introduction
When testing RTB scripts on production, constant deployments slow down the process and increase the risk of system disruptions. This makes it frustrating to quickly validate script changes, especially for minor adjustments.
With Requestly, you can bypass deployments altogether by injecting your local RTB scripts directly into the live environment. This allows you to test in real-time, saving time and reducing the risks associated with frequent deployments.
Test RTB Scripts on Production

- Replace: This allows you to specify which part of the URL you want to replace. In this case,
https://rtb.comis the URL segment being modified. - Replace With: This indicates what the original URL should be replaced with. In this instance,
https://rtb.comis replaced byhttp://localhost:3007. - Source Condition: This allows you to set up specific conditions, such as URL patterns, to target particular domains or requests. For example, the URL is set to
https://rtb.com - 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 test local RTB scripts on client websites using Requestly’s Replace Rule:
- Open Requestly:Open Requestly app.
- Create a New Rule: Click
New Ruleand choose theReplace Ruleoption. - Define the URL Pattern: Enter the
URLwhere you want to inject the local RTB script. - Configure the Replacement: Enter the URL of your
local RTB scriptin the replacement field to swap it with theexisting script. - Save the Rule: Click
Saveto apply the rule.
Interactive Guide
Check this interactive and easy explanation of how to use Replace String Rule
Conclusion
Try this Replace Rule to load and test a local RTB script on production without deploying. This approach ensures you can evaluate your script in the live environment without affecting the actual data. Requestly is used by over 200k developers and 1000+ companies for efficient network request management.
Explore More:
Written by
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​
[sibwp_form id=1]
Share this article
Related posts
Get started today
Join 300,000+ developers building smarter workflows.
Get Started for Free
Requestly Works on Desktop Only
Requestly isnât available for download on mobile or tablets.
To download it, please open this page on a desktop PC and enter your email to get the link.
Mac app
Lightweight & Privacy-first API Client
- Local Projects
- Organize API into Collections & Environments
- API Tests
- Import from Postman, OpenAPI, etc
Download Now
Chrome extension
Intercept & modify HTTP requests/responses
- Redirect URLs & modify HTTP headers
- Mock API / GraphQL responses
- Insert custom JavaScript scripts
Add To Chrome









