Installing Rust
Rust is installed with rustup, the official toolchain installer. It installs the compiler and tools, and later keeps them up to date. This course targets Rust 1.85 or newer and the 2024 edition — any newer stable release works too.
- macOS and Linux — run this in a terminal and accept the default option:
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
- Windows — download and run
rustup-init.exefrom rustup.rs. Rust on Windows needs the Microsoft C++ build tools; the installer offers to install them through Visual Studio if they are missing — accept that.
rustup installs three main tools:
rustc— the Rust compiler.cargo— Rust's build tool and package manager. You'll use it for almost everything.rustup— manages the installed toolchains themselves.
Open a new terminal and check the installation:
rustc --version
cargo --version
rustc 1.85.0 (4d91de4e4 2025-02-17)
cargo 1.85.0 (d73d2caf9 2024-12-31)
Your version numbers will match whatever release you installed. If
the terminal says command not found (or "is not recognized" on
Windows), reopen the terminal so it picks up the updated PATH.
Release channels
Rust ships on three channels:
- stable — a new release every six weeks. Use this; it's the default.
- beta — the next stable release, for testing.
- nightly — built every night and includes experimental features. Some advanced libraries need it, but you won't in this course.
Useful rustup commands:
rustup update # update to the latest stable release
rustup toolchain install nightly # install nightly alongside stable
rustup doc # open the offline documentation
rustup doc opens a local copy of the standard library docs and
The Rust Programming Language book — handy when you're offline.