How to install Perl on a computer

Updated: 12/05/2021 by Computer Hope

The Perl programming language is available for all major platforms. To install Perl on your computer, select your operating system from the list below and follow the instructions.

Microsoft Windows

To run Perl in a Windows environment, we recommend using Strawberry Perl, which contains all you must develop Perl scripts for use in Windows and other platforms.

Tip

To use Perl in a Linux environment under Windows, you can also use WSL (Windows Subsystem for Linux). Once Linux is installed and running on your computer, it includes Perl.

To install Perl using Strawberry Perl, follow the steps below.

  1. Visit the Strawberry Perl website and download the 32-bit or 64-bit version. If you have no intentions of running your scripts on older computers, we suggest the 64-bit version.
  2. Once the file is downloaded, run the install file and complete each of the steps.
  3. After the install is complete, you are returned to Windows.

To verify Perl is installed and accessible, open the Windows command line and type the following command.

perl -v

If the Perl version information is displayed, you have Perl installed on your computer. If the command line gives you an error, Perl is not installed.

Apple macOS

Perl is automatically installed and accessible through the Terminal. You can verify if Perl is installed and accessible by typing the following command.

perl -v

If the Perl version information is displayed, you have Perl installed on your computer.

Chromebook

The latest Chromebooks support the ability to have Linux installed and accessible through a command line. If Linux has not been installed on your Chromebook, see the following link.

Once Linux is installed, you can verify if Perl works on your Chromebook by typing the following command.

perl -v

If the Perl version information is displayed, you have Perl installed on your Chromebook.

Linux

If you're running any variant of Linux, Perl should already be installed. You can verify if Perl is installed and accessible by typing the following command.

perl -v

If the Perl version information is displayed, you have Perl installed on your computer.