Windows where equivalent in Linux
Locates the full path of an executable command or program.
where
which / whereis
which / whereis
which / whereis
Overview
What this command does
On Windows, "where" is used to find where a command is installed. On Linux, the closest practical mapping shown here is "which / whereis". Locates the full path of an executable command or program. This reference is grouped under Package Management.
Windows → Linux context
What changes when you use this on Linux?
Equivalent task, different tool
Windows where maps to which / whereis for this task. Treat this as a workflow mapping rather than a character-for-character syntax translation.
Portable across the compared distros
The Debian/Ubuntu, Fedora and Arch rows use the same command in this mapping. Package availability or defaults can still vary, so check the installed tool version when an option behaves differently.
For the broader concept behind this mapping, read Linux package management.
Practical tasks
Common use cases
Find where a command is installed
Locates the full path of an executable command or program.
which python3
Path to python3 executable
whereis git
Binary, man page, and source paths
type ls
Shows if it's an alias, function, or binary
Ready to run
Copyable Linux commands
Review paths, device names, package names and permissions before running any command.
which python3
which git
whereis nginx
type ls
Walkthrough
Examples with explanations
# Windows: where python
which python3 # /usr/bin/python3
which git # /usr/bin/git
whereis nginx # binary + man page locations
type ls # ls is aliased to 'ls --color=auto'
Reference
Common options and variations
| Command or option | Use |
|---|---|
which python3 | Path to python3 executable |
whereis git | Binary, man page, and source paths |
type ls | Shows if it's an alias, function, or binary |
command -v curl | Script-safe way to check if cmd exists |
Distro differences
Debian/Ubuntu vs Fedora vs Arch
Debian/Ubuntu, Fedora and Arch all use "which / whereis" for this mapping. The command syntax shown here is portable across the three rows, although installed versions and system defaults can still vary.
| Distribution | Package manager / base | Equivalent command | Difference to notice |
|---|---|---|---|
| Debian/Ubuntu | same command | which / whereis |
Same command on this distribution. |
| Fedora | same command | which / whereis |
Same command on this distribution. |
| Arch | same command | which / whereis |
Same command on this distribution. |
Keep learning