3 Things You Might Not Know About the Chrome Network Tab
Tags: webdev, webperf, uiweekly, chrome
Published: 2020-09-14 02:06:40

If you've ever needed to understand the details of a web page's interaction with network resources, you're likely familiar with the Network tab of you browser. 

In this post I'm going to describe 3 (possibly) lesser known features related to the Chrome Network tab.  

# 1. Customizing the view
Once you access the Chrome Network tab you are presented with the standard view.  This is what I see when I view the Network tab for the dev.to home page:
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/sp35vnzj2oepi2gkhrzc.png)

As you can see above, the dev.to page has a number of resource types, including jpeg, script, xhr, png, etc.  You can limit your view to a single resource type by selecting that type in the filter ribbon.  For example, this view is filtered to display script resources:
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/mcta9oz7wo9q48nik32g.png)

OK that's relatively basic and you might know that already, but did you know you can view additional data, edit the sort order, customize the view of the waterfall column, and more?  All of this can be accomplished by right clicking on one of the resource columns and making your selections from the context-sensitive menu:
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/wevcep77kp6zflxmps85.png)

# 2. Capturing Screen Shots
In addition to the wealth of textual data available, you can also view screenshots of the page as it loads.  To do that, just click the gear icon on the upper right. then check the "Show overview" and "Capture screenshots" checkboxes:
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/a9rietafzuzs371u8ny6.png)

After making those changes and refreshing the page you'll see screen shots of the page as it loads:
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/50mf4bqayj4vei98394v.png)

You can click on an image to jump to the associated network activity below, or double-click the image to get a better look:
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/ka33ggfvxupdq5s79nkv.png)

# 3. The HTTP Archive File
All of the details captured by Chrome can be saved to a file; an HTTP Archive File.  This HAR file contains all the network details in JSON format.  

Capturing this data in a file allows you to save details from a session, share with other team members, load into Chrome developer tools, or perform further analysis with 3rd party HAR analysis tools.  In addition, tools like Gatling use a HAR file as input into a process for generating load test scripts.  I talked about this in my [Gatling post](https://dev.to/leading-edje/automated-performance-testing-with-gatling-a04) (shameless plug).

To save the Chrome session info to a HAR file, just right-click in the network traffic table and selected "Save all as HAR with content" from the context-sensitive menu:
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/1wta0aq0da00j2fyrv7y.png)

There are a number of online HAR viewers, but one I've used that I like can be found at http://www.softwareishard.com/har/viewer/

Drag your HAR file onto the page and you'll see an interactive visual of your HAR file:
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/06nwgeb6powxwmhkw8ud.png)

Of course Google has a HAR analyzer also:
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/foqyu7psl3p37x7fztlf.png)

Go ahead and explore and see what works for you.

#Wrap-up
Chrome has plenty of other features available in the DevTools, and you can checkout out lots more at the [Chrome DevTools page](https://developers.google.com/web/tools/chrome-devtools/network).

I hope you've learned something from this post.  Maybe you have your own tips and tricks for Chrome DevTools?  If so, feel free to mention them in the comments!

Happy browsing!

<a href="https://dev.to/leading-edje">
  ![Smart EDJE Image](https://dev-to-uploads.s3.amazonaws.com/i/5uo60qforg9yqdpgzncq.png)
<a/>