How to install Ubuntu in VirtualBox

You don’t need a dedicated laptop or desktop to run Ubuntu, you can run it in a virtual machine through Virtualbox instead.

Installing Ubuntu in Virtual box

If you’re curious and want to try Ubuntu, one of the most popular Linux distributions, we have some good news. It is not necessary to install the operating system in place of Windows 11 or even macOS on a laptop or a desktop. You can safely run the open-source operating system virtually, separate from your primary OS, and on over it in a virtual machine.

VirtualBox, designed by the folks at Oracle, is one of the most reliable virtual machines for users. It’s free, and thanks to the user-friendly interface, getting started is simple.

How to install Ubuntu in VirtualBox

Installing Ubuntu in VirtualBox is a multistep process. First, VirtualBox will need to be downloaded and installed. Then, the preferred ISO file for the Ubuntu version you’d like to use must also be downloaded. Once you have those two things, you can head into VirtualBox and follow the guided wizard to set up an Ubuntu installation.

  1. Navigate the VirtualBox website and download the latest version of VirtualBox. (Currently, it is 7.0.12. Make sure you click the proper host OS. There are options for Windows, macOS, and Linux.)
  2. Double-click to launch the downloaded file to set up VirtualBox. (Your internet connectivity will briefly be interrupted as part of the setup while the network interfaces are installed.)
    A screenshot of the first setup screen of Oracle VirtualBox on Windows 11
  3. Uncheck the box to Start Oracle VM VirtualBox. We won’t need the app open right now, as we’re going to download Ubunutu first. Click Finish.
    A screenshot of the initial setup screen on Oracle VirtualBox showing not to start it after installation
  4. Navigate to the Ubuntu download webpage. Choose the latest LTS version, which has the most support. (As of writing, it’s Ubuntu 22.04.3 LTS.)
  5. Wait for the ISO to download. It could take a while depending on your internet speed.
  6. Once the download is complete, launch VirtualBox. At the top of the app, choose New.
    A screenshot of creating a new virtual machine in Oracle VirtualBox for Ubuntu on Windows 11
  7. Give your Virtual Machine a name. For this example, we’re calling it Ubuntu.
  8. Under ISO Image click the down arrow and choose Other.
  9. Navigate to where Ubuntu’s ISO file is saved and click Open.
    A screenshot of picking an ISO file to load into a virtual machine in Oracle ViirtualBox on Ubuntu
  10. Check the box for Skip Unattended Installation, then, Click Next.
  11. Adjust the base memory available to Ubuntu. The more the better, since it will run faster. Keep in mind, if your primary system is low on physical RAM, the lower, the better to avoid slowing your main system too much. We suggest leaving it at the suggested amount.
    A screenshot of adjusting the base virtual memory for Ubuntu on VirtualBox on WIndows 11
  12. Adjust the processors available. We suggest leaving it at the suggested amount.
  13. Click Next and choose a size for your virtual hard disk. This is the space Ubuntu will be taking up. Again, the higher, the better. However, if your PC is low on space, the lower, the better. The installer will suggest an amount it thinks is right for your system.
    A screenshot of adjusting the cpus for Ubuntu on VirtualBox on WIndows 11
  14. Click Finish.
  15. Once the virtual machine is added, click the Start button to get it running. To control the virtual machine, your primary keyboard and mouse movements will automatically be captured when you hover into the active VirtualBox window. To return control to your main OS, just click outside the window. If you’re noticing issues with your keyboard or mouse, VirtualBox assigned you a Host Key that can be used to swap the keyboard and mouse manually to enter and exit control of the virtual machine. Usually, it is set to the Right Control Key.
    A screenshot showing how to start an Ubuntu virtual machine in VirtualBox on Windows 11
  16. Press Enter on the Try or Install Ubuntu option. If the sidebar bothers you, click the Delete notification button on the top left of the window to dismiss it.
    A screenshot of the initial GRB menu of Ubuntu in Oracle VirtualBox on Windows 11
  17. Click the Install Ubuntu option and follow the steps on your screen.
  18. We suggest choosing Normal Installation choosing to Download updates while installing Ubuntu, and Install third-party software.
  19. If prompted, choose Erase disk and install Ubuntu.
  20. You can give your install a name, and password, and continue with setup. You’ll be prompted to reboot, and when finished, you’ll be taken to your virtual Ubuntu desktop.

Additional Tips

That’s it! You’re now up and running with Ubuntu on Virtual Box, but we have some additional tips. If you’d like, you can take your new Ubuntu to install in Virtual Box full screen. To do this, just click inside the virtual machine, and hit the Host Key, and F. You also can do this from the main menu by clicking View and Full Screen. Whenever you’re ready to shut down Ubuntu, you turn it off like you would a regular Ubuntu machine. Or, you can close the VirualBox window, and choose to Save the machine state to get back to what you were doing easily.

Keep in mind, though, that Ubuntu is still running on a virtual machine. Depending on your computer’s age and CPU and other specs, the performance might not be the best. But this is still a great way to experience Ubuntu for the first time with little harm to your main PC or Mac. Everything you do is separate from your main operating system since it is running in a virtualized environment. It’s a great way to learn Ubuntu or Linux, and become a master of the open source operating system.