I am debugging an API request in Firefox and I am looking to filter multiple domains in the developer tools' Network panel. I can filter by one domain with the domain:domainname.com
, but how do I add additional domains?
There are three ways to open the debugger: Select the Debugger panel in the Web Developer Tools, accessible from the Browser Tools submenu. Press Ctrl + Shift + Z on Windows and Linux, or Cmd + Opt + Z on macOS (starting in Firefox 71; prior to Firefox 66, the letter in this shortcut was S ). Press the menu button.
The Network view allows you to see and analyze the network requests that make up each individual page load within a single user's session. You can use this view to investigate the causes of slow pages and identify performance bugs.
Filtering by two domains is not directly possible because the filters in the Network panel is always accumulative, though one workaround is to use a regular expression filter.
This allows you to provide several domains separating them by pipes like this:
regexp:domain1.com|domain2.com
That should work in most cases, but note that this is not just filtering by domain but searching within all the data inside the requests. That means that when the domain name appears in one of the other columns, the request will also be listed.
Another way to achieve this is to use negative filtering by prepending the filter expression with a minus.
So in order to get the requests of two domains you have to write several -domain:
expressions for all domains you want to exclude.
There's also the regexp
keyword to use Regular Expressions for URL filtering.
https://developer.mozilla.org/en-US/docs/Tools/Network_Monitor/request_list#Filtering_by_properties
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With