Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
The PowerShell Gallery supports downloading a package from the website directly, without using the
PowerShellGet cmdlets. You can download any package as a NuGet package (.nupkg) file, which you
can then copy to an internal repository.
Note
Manual package download is not intended as a replacement for the Install-Module cmdlet.
Downloading the package doesn't install the module or script. Dependencies aren't included in the
NuGet package downloaded. The following instructions are provided for reference purposes only.
Using manual download to acquire a package
Go to the PowerShell Gallery: https://www.powershellgallery.com
In the search box, search for the module or script name.
Select the package you want from the results.
On the package details page under Installation Options, select the Manual Download tab.

Select Download the raw nupkg file. A copy of the package is copied to the download folder for your browser with the name
<name>.<version>.nupkg.
A NuGet package is a ZIP archive containing information about the contents of the package. To expand
the package, rename the .nupkg file to .zip and extract the contents to a local folder using
Expand-Archive or some other ZIP file tool.
A NuGet package file includes the following NuGet-specific elements that aren't part of the original packaged code:
- A folder named
_rels- contains a.relsfile that lists the dependencies - A folder named
package- contains the NuGet-specific data - A file named
[Content_Types].xml- describes how extensions like PowerShellGet work with NuGet - A file named
<name>.nuspec- contains the bulk of the metadata
Remove these elements to leave the PowerShell code created by the package author.
Installing PowerShell modules from a NuGet package
Note
These instructions DO NOT give the same result as running Install-Module. These instructions
fulfill the minimum requirements. They aren't intended to be a replacement for Install-Module.
Some steps performed by Install-Module aren't included.
The steps are as follows:
- Unblock the Internet-downloaded NuGet package (
.nupkg) file, for example usingUnblock-File -Path C:\Downloads\module.nupkgcmdlet. - Extract the contents of the NuGet package to a local folder. The default folder name is usually
<name>.<version>. - Delete the NuGet-specific elements from the folder.
- Rename the folder to just the module name. Create a subfolder named based on the version of the module.
- Move the contents of the extracted folder into the version-specific subfolder.
- Copy the folder to one of the folders in the
$env:PSModulePathvalue.$env:PSModulePathis a semicolon-delimited set of paths in which PowerShell should look for modules.
Important
The manual download doesn't include any dependencies required by the module. If the package has dependencies, they must be installed on the system for this module to work correctly. The PowerShell Gallery shows all dependencies required by the package.
Installing PowerShell scripts from a NuGet package
Note
These instructions DO NOT give the same result as running Install-Script. These instructions
fulfill the minimum requirements. They aren't intended to be a replacement for Install-Script.
The easiest approach is to extract the NuGet package, then use the script directly.
The steps are as follows:
- Unblock the Internet-downloaded NuGet package (
.nupkg) file, for example usingUnblock-File -Path C:\Downloads\package.nupkgcmdlet. - Extract the contents of the NuGet package.
- The
.PS1file in the folder can be used directly from this location. - You may delete the NuGet-specific elements in the folder.
For the list of NuGet-specific elements, see Using manual download to acquire a package.
Important
The manual download doesn't include any dependencies required by the module. If the package has dependencies, they must be installed on the system for this module to work correctly. The PowerShell Gallery shows all dependencies required by the package.
PowerShell Gallery