0 Shares 29211 Views

A step-by-step guide to generating a HAR file.

In this blog post, we will be discussing what HAR file is, what it does and why would you use it. We will also share with you a step-by-step guide to generate and open a HAR File format, along with some screenshots and explanations.

So let’s get started.

  • What is HAR File?

HAR (HTTP Archive Format) is a JSON archive file format that stores session data over many browsers (IE, Firefox, Chrome, Safari, etc.) between client and server. In the network environment, when the communication between the sender and the receiver occurs, HAR contains HTTP response and request headers. The extension of the HAR file format is “.har”.

  • What Does HAR File Do?

The HAR file is used to save the information of all web requests made with the browser tab. This file is a format that enables the detection of bottlenecks and vulnerabilities by system experts, developers or security testers.

  • Why Use HAR Files?

We can list Our clients’ website performance problems as a bottleneck, long load times, and page render processing times that cause too much load to the computer’s processor. As a solution to these problems, the HAR files should be checked in order to solve the efficiency of the site performance of our clients as soon as possible. In order to analyze the HAR files well, you need to know how to generate one and perform the below-mentioned steps correctly.

  • How to Generate a HAR File?

In the analysis process, you need to create a HAR file according to the type of browser you are using. The following steps are given to show how to create the Har File record for some browsers.

 Generating a HAR File in Google Chrome

Follow the steps below, to create a HAR file in a Chrome browser for a specific URL.

HAR File Chrome

  1.  Open your Chrome browser and click on the web page where the problem happened.
  2. Open the developer tool (inspect element). (Shortcut for Windows: CTRL + Shift + i, CMD + alt + i for Mac).
  3. Then, select the Network tab.
  4. Go to the left of the panel to start the file recording. There is a small round red button in this section. (WARNING: If the specified round button is red, it starts recording. So, you don’t need to click on the button. If the button is grayed, you have to press it and start it.)
  5.  Click the to “Clear icon” to delete any log records kept in the browser.

HAR File Chrome

6. To save the content you want as shown above, right click and click “Save as HAR                File”

Generating a HAR File in Firefox

  1.  Open your Firefox browser and click on the web page where the problem happened.
  2.  Open the developer tool (shortcut for Windows: CTRL + Shift + i, CMD for Mac + alt + i).
  3. Click the Network tab
  4. Press F5 to refresh the page.
  5. Click ”Save as with Content“ to save.
  6. Select and save the file.

HAR File Firefox

Generating a HAR File in Safari

  1. Open your Safari browser and click on the web page where the problem happened.
  2. Press “Option + Command + i” as a shortcut to view the page.
  3. Click ”Export as HAR File.“ On the Network tab.

HAR File Safari

Generating a HAR File in Internet Explorer

  1. Open your Internet Explorer browser and click on the page where the problem happened.
  2. Press F12 on your keyboard.
  3. Click the Network tab.
  4. Click the option “Save”.
  5. You can analyze your HAR file using the HTTP Archive Viewer tool.

HAR File Internet Explorer

  • How should we open the HAR file format?

HAR Viewer tool helps display the contents of HAR files. With the help of Har Viewer, log file records, HTTP request, and response header information can be viewed. To view the HAR file contents; If you’re using Chrome, you can use the HTTP Archive Viewer plug-in, if you’re not using it you can use the online Viewer tools. Follow the two steps given below to view the contents of the HAR files.

  1. Click  “Choose File” button in HAR Viewer tool to view the HAR file you saved or you can view the contents of the file by copying it to the empty box.

HAR File

2. Select “Inspect” tab to display HTTP session data in HAR Viewer.

HAR File

 

If you reached this point, you will know how to generate HAR file on different browsers without any problem. I hope that was helpful.

free trial CDN

 

 

You may be interested

The Ultimate CDN (Content Delivery Network) Guide
CDN
3987 views
CDN
3987 views

The Ultimate CDN (Content Delivery Network) Guide

Nadia Benslimane - August 3, 2020

The Ultimate CDN Guide- Everything About Content Delivery Network You probably know what CDN (Content Delivery Network) stands for. You may also be aware of its full definition,…

The Essential CDN Glossary
CDN
9022 views
CDN
9022 views

The Essential CDN Glossary

Nadia Benslimane - November 21, 2019

Why Have We Decided To Create a CDN Glossary? Whether you are new to the world of CDN, or have been involved in it for years, there…

NodeJS Express for JWT Auth Example
Software Learning Center
88 views
Software Learning Center
88 views

NodeJS Express for JWT Auth Example

Tolga Karabulut - June 1, 2021

Hello everyone 👋 In this article, I will tell you how to use JSON Web Token (JWT) through the Express Framework. Previously, I explained JWT in general…

A Comparison Between Edge Containers and Other Edge Computing Solutions
CDN
141 views
CDN
141 views

A Comparison Between Edge Containers and Other Edge Computing Solutions

Tushar Sonal - May 21, 2021

The client-server computing architecture has been a prevalent paradigm in the computing world. And it has been revolutionary in serving powerful applications and supporting critical use cases…

How CDN Providers are Meeting Surging OTT Demand in 2021
Uncategorized
227 views
Uncategorized
227 views

How CDN Providers are Meeting Surging OTT Demand in 2021

Tushar Sonal - May 10, 2021

The OTT, or Over-the-Top video content is a trend that’s been growing phenomenally over the last few years.  According to a study by the Allied Market Research,…

Most from this category

The Ultimate CDN (Content Delivery Network) Guide
CDN
3987 views
3987 views

The Ultimate CDN (Content Delivery Network) Guide

Nadia Benslimane - August 3, 2020
The Essential CDN Glossary
CDN
9022 views
9022 views

The Essential CDN Glossary

Nadia Benslimane - November 21, 2019
SERVICE MESH vs. API GATEWAY
Technology
282 views
282 views

SERVICE MESH vs. API GATEWAY

Emir Turna - April 6, 2021
How Can AI Be Used to Beat Video Piracy
OTT
473 views
473 views

How Can AI Be Used to Beat Video Piracy

Tushar Sonal - March 25, 2021