How to completely uninstall Nvidia drivers in Ubuntu?

To completely uninstall the NVIDIA driver, you can follow these steps:

  1. Open the terminal and access the command line interface.
  2. Run the following command to stop the relevant NVIDIA services:
  3. Please stop the lightdm service using sudo.
  4. Alternatively
  5. Stop the GDM service using sudo.
  6. Or alternatively
  7. Please stop the sddm service.
  8. This depends on the display manager you are using.
  9. Run the following command to uninstall the NVIDIA driver:
  10. Remove all packages related to nvidia using the command sudo apt-get purge nvidia*
  11. This will remove all software packages related to NVIDIA drivers.
  12. Run the following command to delete any remaining NVIDIA configuration files:
  13. Remove the xorg.conf file located in /etc/X11 using sudo.
  14. Remove the directory /etc/X11/xorg.conf.d/ using superuser privileges, forcefully.
  15. Run the following command to reinstall the default open-source Nouveau driver:
  16. Install xserver-xorg-video-nouveau using the given command.
  17. Finally, restart the computer.
  18. restart the system with administrative privileges

After completing the above steps, your system will no longer be using the NVIDIA driver.

bannerAds