How to install VirtualBox on Mac OS X

May 5, 2021

VirtualBox is a virtualization software which we can be used to create and run virtual machines. A virtual machine is like having a computer inside your computer. We can run a different operating system on the virtual machine.


VirtualBox can be downloaded from their website at the following url:
https://www.virtualbox.org/wiki/Downloads


You have to download two files.

The first file is located under the VirtualBox platform packages section. For Mac OS X you would have to click on the OS X hosts link.

The second file you would need to download is located under the VirtualBox Oracle VM VirtualBox Extension Pack section. You would have to click on the All supported platforms link


You should have downloaded the following two files shown on the following screenshot.
At the time of this writing the current version of VirtualBox is the version 6.1.22.




We start the installation by double clicking on the file with the dmg extension.
A popup window will show the progress of the opening of the file.




Once the dmg file has been opened you will see the next window.
Double Click on the first icon, at the top left corner. It is the icon with the VirtualBox.pkg name




Then it will come a verification process...




After that you will be notified that the program will determine if it can be installed. Click Continue




And you will be shown a Welcome screen!
Click the Continue button.




Click on the Install button.




A popup windows notifies you that Installer is trying to install new software.
Enter your computer admin user's password...




After that the Installing Oracle VM VirtualBox process will start.


The process have several steps, such as Writing files...




... Running package scripts....




As the installation process needs to set up system extensions, you will be shown a popup window alerting you that the process has been blocked.
This is normal due to the security protections implemented on Mac OS X. In order to proceed we have to authorize this software to be installed.


Click on the Open Security Preferences button.




Open the Security window, and click on the Allow button located on the bottom half of the window.




However, as the process was blocked, the installation would have been interrupted. This caused the installation to fail.
Click on the Close button.




A popup window will ask if we want to move the installer to the Trash. Click on the Keep button.





We have to restart the installation process by double clicking on the dmg file again, and repeat all the installation steps.




-- All of the installation steps are repeated --



After the above steps are repeated again, we will finally succeed in installing VirtualBox.