What's the Best Way to Install Software from a .tar.gz File?

September 23, 2025 5 answers
Asked by saffron_risotto
I've been using Linux for over a year now, and even after all this time, I still struggle with installing software from .tar.gz files. Is the process similar to Windows where I just extract and run the files? Or do I need to move them to a specific directory like "/usr/bin"?

Answers

tUcked in
You can run the binary directly after extracting it, but if you want to use it from anywhere, copying it to /usr/local/bin or /usr/bin is a good call, depending on your system setup.
Reply to this answer
plumage-
Make sure to check what the .tar.gz file actually contains. If it has a Makefile, avoid using 'make' and 'make install' without checking first, as that compiles from source. Ideally, find a repository that has pre-compiled packages for easier installation.
Reply to this answer
moss identification
If it's source code, you might need to compile it first. If it's just a binary file, you can run it directly after extracting. For easy access, consider moving it to ~/.local/bin and make sure itโ€™s in your $PATH!
Reply to this answer
Circuit.Lab
Generally, you want to extract the contents and then check for any documentation like README or INSTALL files. They usually have specific instructions on what to do next.
Reply to this answer
-before-and-after-
Just remember that .tar.gz means it's a compressed archive, and you'll need to use tar to extract it. After that, what you do next depends on the contents of that archive.
Reply to this answer

Add your answer

Answers are reviewed before publication.

Related Discussions