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

A HAR file is commonly used to troubleshoot community or efficiency points, together with poor web page load occasions and timeouts when performing sure duties on an internet site.

The assist crew of any firm or web site makes use of this HAR file to determine and resolve efficiency points akin to longer or sluggish load occasions, web page rendering points, and error codes which will happen on account of these points.

What’s a HAR file?

An HTTP archive format, also called a HAR file, is a JSON-formatted archive file that accommodates your most up-to-date community exercise as recorded by your internet browser. It tracks all interactions akin to internet requests and responses between an internet browser and an internet site.

difficult

The HAR file information every useful resource loaded by the browser, in addition to the time it took for every useful resource to load. These information comprise plain textual content logs of HTTP client-server connections.

.her is the extension for these archive information.

Why generate a HAR file?

The corporate or enterprise assist crew can request the HAR file for evaluation when the consumer submits a ticket to resolve the problems.

HAR information present all kinds 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 response information, the period of time it took to load a given picture on the web site, the time it took to determine a server connection, and the time it took to ship a request and obtain a response.

Overview of the method

  • First, go to the webpage the place you are having issues and begin recording all internet requests and interactions.
  • Recreate the issue by repeating the steps.
  • End recording and save the HAR file.
  • Analyze the HAR file your self or ship the file to the assist crew for efficiency and web page rendering troubleshooting.

The best way to generate a HAR file in numerous browsers?

The era of HAR information for capturing an HTTP session varies from browser to browser.

Chrome

The Community tab in Developer Instruments of all browsers can be utilized to document an HTTP session.

  • In Chrome, go to the web page the place you are having an issue.
  • Developer instruments will be accessed from the menu (Menu > Extra instruments > Developer instruments). In it, choose the Community tab within the newly opened panel.
  • Within the Community tab, ensure the spherical button within the prime left nook is pink. If it is grey, double-click it to document the interactions.
  • Allow the retention log to document all internet requests and responses.
  • To export the HAR file, click on the down arrow on the community tab itself.
  • Save the HAR file to your pc.
Har file in Chrome

Firefox

  • Within the prime proper nook of your browser window, click on the Firefox menu (three horizontal, parallel strains).
  • Choose Extra instruments > Internet developer > Community from the drop-down menu.
  • Click on the Settings button and allow the logging possibility.
  • Whereas the seize is in progress, refresh the web page and retry the problem.
  • Proper-click on any row of the exercise panel and choose Save all as HAR if in case you have efficiently replicated the problem.
  • Lastly, if a console log file can also be wanted for troubleshooting, then navigate to the Console tab and Choose All by right-clicking on any row and pasting the contents right into a textual content file and sharing it with the assist middle .

Microsoft Edge

  • Choose Extra Instruments > Developer Instruments by clicking … (the three-dot icon) within the top-right nook.
  • Navigate to the Community tab and begin a profiling session.
  • Go to the net web page and observe the directions to resolve the problem.
  • And at last save the HAR file by deciding on “Export as HAR”.

Web Explorer

  • Open the web explorer and go to the web page the place you might be having issues
  • click on on the gear image within the prime proper nook.
  • Go to (Developer Instruments > Community tab)
  • Whereas the seize is in progress, refresh the web page and replicate the problem.
  • Click on the “Export as HAR” icon (the form of a floppy disk) after efficiently replicating the issue.

HTTP Watch instrument

For Google Chrome, Web Explorer, and Microsoft Edge, you can even use HTTPWatch (in-browser HTTP sniffer) to seize internet requests and responses.

  • First, obtain and set up the HTTPwatch instrument.
  • Begin the HTTPwatch recording and cargo the web page the place you are having points, then cease the recording as soon as you have replicated the problem.
  • And the fixation ought to are saved in HER format.

Web sites to research HAR information

These instruments are easy and efficient in visualizing and analyzing the HAR file (HTTP client-server communication logs).

  • Google HAR Analyzer – Select a file by clicking the ‘Select File’ button and choose the HAR file you need to look at. The Evaluation display seems mechanically after you select the file. Filtering by HTTP standing code is offered.
  • Softwareishard.com – A free web-based utility instrument that shows a waterfall chart of all requests and lets you seek for a selected request. Press the Preview button after inserting the HAR log into the textual content field beneath. It’s also possible to drag and drop the har information anyplace on the web page to research the file.
  • Site24x7 – That is additionally a free web site instrument to visualise the HTTP archive file. Browse the file or paste its contents into the edit field.

Conclusion

In the event you open a HAR file in a textual content editor, you will discover that it is merely a JSON doc that accommodates your internet request and its responses. It might comprise the next doubtlessly delicate info:

  • Request and response headers
  • Request and response content material
  • Authentication tokens, cookies, session tokens, passwords and API credentials

Be sure that to take away all delicate info from HAR information earlier than sending it to a assist crew for evaluation. If the tech assist crew requests a HAR file of third-party interactions, important info specifically will be uncovered.

I hope you discovered this text very useful in studying about HAR evaluation instruments and generate HAR information in numerous browsers.

You might also be fascinated by troubleshooting community latency points with Wireshark.

Rate this post
Leave a Comment