How to Create HAR File from Google Chrome, Firefox, and Analyze it?


A HAR record is repeatedly used to troubleshoot networking or efficiency problems, together with deficient web page load occasions and timeouts when doing explicit duties on a web site.

Any corporate or web site’s make stronger crew makes use of this HAR record to establish and get to the bottom of efficiency problems akin to longer or sluggish loading occasions, web page rendering problems, and error codes that can get up due to those problems.

What is a HAR record?

An HTTP archive Format, often referred to as a HAR record, is a JSON-formatted archive record that incorporates your most up-to-date community process as recorded by way of your information superhighway browser. It tracks all of the interactions, akin to information superhighway requests and responses between a information superhighway browser and a web site.

harfile

The HAR record information each and every useful resource loaded by way of the browser, in addition to the time it took to load each and every useful resource. These recordsdata comprise simple textual content logs of HTTP client-server connections.

.har is the extension for those archive recordsdata.

Why to generate HAR record?

The corporate or trade make stronger crew would possibly ask the HAR record for research when the person raises a price tag to get to the bottom of the problems.

HAR recordsdata supply quite a lot of details about HTTP client-server requests and responses that assist in debugging, akin to browser settings and cookies, the period of time spent getting reaction knowledge, period of time it took to load a specific image at the web site, the time it took to identify a server connection, and the time it took to ship a request and to obtain a reaction.

Overview of the method

  • First pass to the webpage the place you’re having problems and start recording all of the information superhighway requests and interactions.
  • Recreate the issue by way of repeating the stairs.
  • Finish the seize and save the HAR record.
  • Analyze the HAR record by way of your individual or Send the record to Support crew for troubleshooting the Performance and web page rendering problems.

How to generate HAR record in several browsers?

Generating HAR recordsdata for shooting an HTTP consultation varies from browser to browser.

Chrome

The Network tab in Developer Tools of all browsers can be utilized to file an HTTP consultation.

  • In Chrome, pass to the web page the place you might be experiencing drawback.
  • Developer Tools can also be accessed by the use of the menu (Menu > More Tools > Developer Tools). In that Select the Network tab from the newly opened panel.
  • On the Network tab, Make positive the spherical button within the higher left nook is in crimson. If it’s gray, double-click it to start recording the interactions.
  • Enable the maintain log to file all of the information superhighway requests and responses.
  • To export the HAR record, click on the down arrow button within the community tab itself.
  • Save the HAR record to your pc.
Har File in Chrome

Firefox

  • At the top-right of your browser window, click on the Firefox menu (3 horizontal parallel traces).
  • Select More gear > Web Developer > Network from the drop-down menu.
  • Click at the settings button and flip at the persist logs choice.
  • While the seize is ongoing, refresh the web page and repeat the issue.
  • Right-click any row of the process panel and make a choice Save all as HAR in case you’ve effectively replicated the issue.
  • Finally, If in case console log record could also be required for troubleshooting, navigate to the Console tab and Select all by way of right-clicking any row and paste the content material in some textual content record and proportion it to the make stronger heart.

Microsoft Edge

  • Select More Tools > Developer Tools by way of clicking on … (the three-dot icon) on the top-right nook.
  • Navigate to the community tab and get started a profiling consultation.
  • Visit the webpage and observe the directions to get to the bottom of the issue.
  • And in any case save the HAR record by way of settling on “Export as HAR “

Internet Explorer

  • Open the web explorer and pass to the web page the place you might be having issues
  • click on the equipment image within the peak correct nook.
  • Go to (Developer Tools > Network Tab)
  • While the seize is ongoing, refresh the web page and mirror the issue.
  • Click the “Export as HAR” icon (form of floppy disc) after replicating the issue effectively.

HTTP Watch Tool

For Google Chrome, Internet Explorer, and Microsoft Edge,  you’ll additionally use HTTPWatch (in-browser HTTP sniffer) for shooting information superhighway requests and responses.

  • Download and set up the HTTPwatch tool first.
  • Start the HTTPwatch seize and load the web page the place you might be having problems and prevent the seize once you’ve replicated the issue.
  • And the seize will have to be stored in HAR structure.

Websites to analyze HAR recordsdata

These gear are easy and efficient in visualizing and inspecting the HAR record (logs of HTTP client-server conversation).

  • Google HAR analyzer – Choose a record by way of clicking the “Choose File” button and make a choice the HAR record you’d like to read about. The Analysis display screen presentations up mechanically after opting for the record. Filtering by way of HTTP standing code is to be had.
  • Softwareishard.com – A loose web-based software device that shows a waterfall graph of all requests and permits you to dig down to a particular request. Press the Preview button after putting the HAR log into the textual content field under. Alternatively, drag and drop the har recordsdata anyplace at the web page to get started inspecting the record.
  • Site24x7 – This could also be a loose web site device to visualize HTTP Archive record. Browse the record or paste its content material in enter field.

Conclusion

If you open a HAR record in a textual content editor, you’ll realize that it’s merely a JSON report containing your information superhighway request and its responses. It would possibly comprise the next probably delicate data:

  • Request and Response Headers
  • Request and Response Content
  • Authentication tokens, cookies, consultation tokens, passwords and API credentials

Make positive you delete any delicate data from HAR recordsdata sooner than filing them to a make stronger crew for research. Mainly, if the technical make stronger crew requests a HAR record with interactions with 3rd events, vital data is also uncovered.

I am hoping you discovered this text very useful in finding out about HAR inspecting gear and how to generate HAR recordsdata in several browsers.

You can be eager about finding out about troubleshooting community latency with Wireshark. 

Related Articles

Leave a Reply

Your email address will not be published.

Back to top button