Use PowerShell to download any file on Windows 10

Windows PowerShell is a tool built into Windows 10. This tool has the ability to set up more features than Command Prompt, better operating system control .... Most likely, PowerShell will replace Command Prompt in the future.

Windows PowerShell is a tool built into Windows 10. This tool has the ability to set up more features than Command Prompt, better operating system control . Most likely, PowerShell will replace Command Prompt in the future.

Microsoft has developed PowerShell for the purpose of automating tasks and configuration management processes. Based on the .NET Framework, PowerShell includes a command line interface and scripting language.

How to use PowerShell to download any file?

To download any file on Windows 10 using PowerShell, follow the steps below:

1. Open PowerShell under Admin. To do this, press the Windows key, then enter powershell in the Search frame. On the search results list, right-click Windows PowerShell (Desktop App) and select Run as administrator.

In the UAC popup window, click Yes.

2. Next copy the link of the file you want to download using PowerShell.

Use PowerShell to download any file on Windows 10 Picture 1Use PowerShell to download any file on Windows 10 Picture 1

3. Copy and paste the following command into Notepad:

$ client = new-object System.Net.WebClient

$ client.DownloadFile ('Download Link', 'File Destinationfile name.file extension')

4. In the above command, replace Download Link with the link you copied in step 2. Insert the location path to download the same file name you want to save with the extension to replace the Destinationfile name.file extension .

Such as the example below:

$ client = new-object System.Net.WebClient

$ client.DownloadFile ('http://thewindowsclub.thewindowsclub.netdna-cdn.com/wp-content/upload/2016/Windows-Explorer-Process-Task-Manager-600x405.png','C:UsersDigdarshanPicturesTWCTask-Manager. png ')

5. Copy the command you have finished editing in the previous step, paste it into the PowerShell window and press Enter to download the file.

Use PowerShell to download any file on Windows 10 Picture 2Use PowerShell to download any file on Windows 10 Picture 2

6. You can now navigate to the download folder path to find the downloaded files stored here.

Use PowerShell to download any file on Windows 10 Picture 3Use PowerShell to download any file on Windows 10 Picture 3

If you download any file, you need to enter some other information such as server login details, . then you can use the following command to download the file:

$ client = new-object System.Net.WebClient

$ client.Credentials = Get-Credential

$ client.DownloadFile ('http://thewindowsclub.thewindowsclub.netdna-cdn.com/wp-content/upload/2016/Windows-Explorer-Process-Task-Manager-600x405.png','C:UsersDigdarshanPicturesTWCTask-Manager. png ')

Refer to some of the following articles:

  1. 10 PowerShell commands help you manage the remote computer most effectively
  1. Add the 'Open PowerShell here' option to the context menu in Windows
  1. 10 new features in Windows Server 2012

Good luck!

4.8 ★ | 4 Vote