How to Create a Virtual Machine in VirtualBox and Install Ubuntu
Want to try Ubuntu without affecting your main Computer or Laptop? VirtualBox lets you do just that! Follow this easy guide to learn How to Create a Virtual Machine in VirtualBox and Install Ubuntu step by step.
Prerequisites
- VirtualBox installed (see our previous guide if you haven’t done this)
- Ubuntu ISO file (Download from: https://ubuntu.com/download/desktop)
- At least 4 GB RAM and 20 GB free disk space
Step 1: Launch VirtualBox and Create a New VM
- Open Oracle VM VirtualBox.
- Click the “New” button.
- Enter a name (e.g., “Ubuntu 24.04”).
- Choose:
- Type: Linux
- Version: Ubuntu (64-bit)
- Click Next.
Step 2: Allocate Memory (RAM)
- Set the memory size — at least 2048 MB (2 GB) is recommended.
- Click Next.
Step 3: Create a Virtual Hard Disk
- Choose “Create a virtual hard disk now” and click Create.
- Choose VDI (VirtualBox Disk Image) → Click Next.
- Choose Dynamically allocated → Click Next.
- Set disk size to at least 20 GB → Click Create.
Step 4: Mount Ubuntu ISO
- With the VM selected, click Settings.
- Go to Storage > Click Empty under “Controller: IDE”.
- Click the disc icon and choose “Choose a disk file”.
- Browse and select the downloaded Ubuntu ISO file.
- Click OK.
Step 5: Start the Virtual Machine
- Select your VM and click Start.
- Ubuntu will boot from the ISO file.
- Choose “Try or Install Ubuntu” when prompted.
Step 6: Install Ubuntu Inside the VM
- Click Install Ubuntu.
- Choose keyboard layout → Click Continue.
- Select Normal Installation and check both download/update boxes.
- Choose Erase disk and install Ubuntu (this affects only the virtual disk).
- Follow on-screen steps to set up username, timezone, and complete installation.
Step 7: Restart and Use Ubuntu
- After installation completes, click Restart Now.
- Remove the ISO when prompted (VirtualBox may auto-eject it).
- Ubuntu will boot from the virtual hard disk.
- Log in with your credentials and enjoy!
You’re Done!
Finally you should have brand new up and running Ubuntu VM in VirtualBox and now you should now how to create virtual machine own your own. At last a tip for your VM is that you chould consider installing Guest Additions provided for your VM by the VirtualBox for enhanced experience.
Conclusion
Installing Ubuntu on a VirtualBox virtual machine is a great way to explore Linux without making permanent changes to your main system. Whether you’re learning Linux, testing software, or just curious, VirtualBox offers a safe and flexible environment. Now that your Ubuntu VM is up and running, you’re ready to dive into the open-source world and explore all that Ubuntu has to offer!
You can explore more informative videos at my YouTube Channel.