# How to open/execute .root file

**URL:** <https://root-forum.cern.ch/t/how-to-open-execute-root-file/51366>\
**Category:** Newbie\
**Created:** [August 26, 2022, 7:58pm UTC](https://root-forum.cern.ch/t/how-to-open-execute-root-file/51366 "2022-08-26T19:58:26Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ema22](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/e/90ced4/32.png) [@Ema22](https://root-forum.cern.ch/u/Ema22)\
**Post date:** [August 26, 2022, 7:58pm UTC](https://root-forum.cern.ch/t/how-to-open-execute-root-file/51366/1 "2022-08-26T19:58:26Z")

</div>

* * *

Hello,  
I’m trying to open .root file, which is the output file of the classification and parameter optimization that I made in c language. I tried root -l filename which only returns the value of the TFile \*. Can you please direct me how to resolve this?  
Thank you

_ROOT Version:_ 6.22.08  
\_Ubuntu Version: 20.04.4 LTS  
\_WSL

---

<div class="post-metadata">

**Author:** ![ferhue](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/ferhue/32/29462_2.png) [@ferhue](https://root-forum.cern.ch/u/ferhue)\
**Post date:** [August 26, 2022, 8:17pm UTC](https://root-forum.cern.ch/t/how-to-open-execute-root-file/51366/2 "2022-08-26T20:17:53Z")

</div>

after running `root -l filename`

write in the terminal:  
`new TBrowser`

and double click on the file on the opened dialog, to access its content.

Alternatively, you can directly run:  
`rootbrowse filename`

---

<div class="post-metadata">

**Author:** ![Ema22](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/e/90ced4/32.png) [@Ema22](https://root-forum.cern.ch/u/Ema22)\
**Post date:** [August 26, 2022, 8:35pm UTC](https://root-forum.cern.ch/t/how-to-open-execute-root-file/51366/3 "2022-08-26T20:35:26Z")

</div>

Thank you very much, everything is working completely fine now!

---

<div class="post-metadata">

**Author:** ![ferhue](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/ferhue/32/29462_2.png) [@ferhue](https://root-forum.cern.ch/u/ferhue)\
**Post date:** [August 28, 2022, 12:59pm UTC](https://root-forum.cern.ch/t/how-to-open-execute-root-file/51366/4 "2022-08-28T12:59:13Z")

</div>

You are welcome. Please ‘mark’ the post above as ‘solution’.
