How to Uninstall Rust Installed via Rustup

Nilesh Katuwal Feb 02, 2024
  1. Uninstall Rust in Linux
  2. Uninstall Rust in Windows
How to Uninstall Rust Installed via Rustup

This article is about uninstalling Rust which was installed via Rustup.

Uninstall Rust in Linux

Use the following codes to uninstall rust, rustup, and cargo in the Linux operating system.

Type the following command in the Linux terminal.

rustup self uninstall

Uninstall Rust in Windows

To uninstall Rust in the Windows operating system, we can run the Rustup installer and select uninstall.

  1. Go to the terminal in Windows and get into the directory where you have installed Rust. Then to see the Rust you have installed, type rustup and click Enter.

    C:\Users\DELL>rustup
    

    Output:

    Rustup CMD

  2. Now check the availability of cargo through the example below.

    C:\Users\DELL>cargo
    

    Output:

    Cargo CMD

  3. Now, to uninstall Rustup, we must enter the following command.

    C:\Users\DELL>rustup self uninstall
    

    Output:

    Rustup Uninstall

  4. Now, for continuing, you have to type y and click Enter. It may take a while to uninstall.

    Confirm Rustup Uninstall

  5. Now Rust will be uninstalled.