Block URLs

Last modified on November 20, 2023

You can command LoadNinja to block requests to certain resources while replaying scripts in the recorder or during load test runs. These resources may include unwanted advertisement banners, tools you use to gather visitor statistics (such as Google Analytics), and so on.

To provide a list of unwanted resources:

  1. Select Add > URLs to block on the script recorder’s toolbar.

  2. In the subsequent dialog, specify the URL of the resource you need to block, then click Add URL.

    Note: You can use regular expressions instead of generic URLs. To learn more, see below.

    The Block URLs button

    Click the image to enlarge it.

  3. Repeat this action to add more URLs, if needed.

    To edit a URL, click .

    To remove a URL from the list, click .

  4. Once done, click Done.

To modify this list later, simply click # blocked URL(s) in the script recorder.

Resource syntax

LoadNinja allows to block both URLs and IP addresses:

  • Block by URL – Use this to block requests by hosts and domains.

    For example:,

    You can use wildcards to block multiple URLs at once:

    • * blocks every host and domain on, including both or
    • *:3000 blocks every request from any resource sent via port 3000, including or
  • Block by IP – Use this to block requests from IP addresses you know to be unwanted, like metric tools.

    For example:,

See Also

UI Test Recorder
Test Web Apps in Local Network
Use Cases

Highlight search results