← All commands
Topic hub Package Management
Windows Linux Package Management

Windows where equivalent in Linux

Locates the full path of an executable command or program.

Windows where
Linux equivalents
Debian/Ubuntu same command
which / whereis
Fedora same command
which / whereis
Arch same command
which / whereis

Overview

What this command does

Locates the full path of an executable command or program.

Migration tip: which shows just the path of the executable. whereis also finds man pages and source files. Useful for knowing which version of a program will run.

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 optionUse
which python3Path to python3 executable
whereis gitBinary, man page, and source paths
type lsShows if it's an alias, function, or binary
command -v curlScript-safe way to check if cmd exists

Distro differences

Debian/Ubuntu vs Fedora vs Arch

This command is the same on Debian/Ubuntu, Fedora and Arch Linux when the relevant tool is installed.

DistributionPackage manager / baseEquivalent commandDifference 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

Related Package Management commands