

$> yslow -info all -format json igvita.har $> yslow -info basic -format plain igvita.har

# download, and unpack PhantomJS: $> phantomjs examples/netsniff.js > igvita.har Alternatively, if you need a quick way to visualize a local HAR file, then the har Ruby gem is indispensable:

HAR viewer is a free and open-source (PHP + JavaScript) application, which you can host yourself, or use the hosted version: paste the HAR data you copied earlier, and you can view the timeline. But you can also feed the data into HAR Viewer, to get an interactive timeline directly in your browser: Great, we can export the network waterfall in HAR format, now what? Well, to start, you can save it for later analysis, or attach it to a bug report - sure beats annotating screenshots of the timeline. Note that you can also export an individual request, or simply copy the JSON data into clipboard. The only notable omission is the response body itself - by default, most tools will only store the meta-data.īut, enough theory, how do we get a HAR file? Simple, in Chrome, open the Network tab in Dev Tools, right click on the waterfall, and there you have it: Save All as HAR. In other words, the HAR file contains all the meta-data that you need to create the network waterfall. Similarly, the response object contains all the associated response data, including response timing data such as timestamps for DNS, SSL handshakes, TCP connect, and wait times, amongst others. In turn, each resource stores the start time of the request, the request method, all the headers, cookies, and payload size. Each HAR file contains a list of loaded pages, and a list of entries for each requested resource for each page - see example. HAR 101: The data formatĪ HAR file is encoded with a simple JSON format, which is both easily created and consumed. Tune in above to check them out, or (and) continue reading for some highlights.

To highlight some of these applications, Peter Lubbers and myself recorded a GDL episode of nothing but awesome demos. The best part about working with HAR data is the number of free tools available to analyze it, visualize it, and even trend it overtime.
