To guarantee compatibility with your projects or system configuration, you may need to use Chocolatey to install a specific version of the software while managing the installation. Software packages can be effectively managed from the command line with Chocolatey, a potent package management tool. To provide you exact control over the versions you require, we'll walk you through the process of installing a particular software package using Chocolatey via CMD in this tutorial.
Table of Content
Install a Specific Version of Software Package using Chocolatey via CMD
Step 1: Opening the Command Prompt on Windows
Click on the Search Menu on the Windows taskbar then search cmd or command prompt.
Step 2: CMD in the search bar
Type "cmd" in the search and r, and the Command Prompt (CMD) will be displayed on the Search Menu.
-660.png)
Step 3: Open Command Prompt as administrator
Click on the run as administrator tab and open the Command Prompt (CMD) along with administrative power.

Step 4: Installation
Run the following code in the Command Prompt to install the package:
choco install <package-name> --version <version-number>You have to replace "<package-name> with the name of the software package you want to install and replace "<version-number>" with the desired version you want to install and use.
Example: For installing Node.js version 14.170, we will run the following command:
choco install nodejs --version 14.17.0Here "<package-name>" is replaced by "node.js" and "<version-number>" is replaced by "14.17.0".

Important note: Not all versions of the software package might be available through chocolatey for use. To check the available versions you can run the following code:
choco search <package-name> --exact --verboseYou have to replace "<package-name>" according to the software package you want to install and use.

This will give all the available software versions available through Chocolatey. (Nodejs versions from the example case)
Conclusion
Software installs across various contexts can be managed with flexibility when using Chocolatey to install a particular version of a package. You can make sure that the right tools are always installed on your machine by learning how to specify versions with the Chocolatey command line. Chocolatey streamlines and expedites the process of installing certain versions via CMD, whether you need an older version or want to use a different one.