PowerTip: Download Links from Webpage with PowerShell

Summary: Use Windows PowerShell to download links from a webpage.

Hey, Scripting Guy! Question How can I use Windows PowerShell to easily download links from a webpage that has a lot of links I want?

Hey, Scripting Guy! Answer Use Invoke-WebRequest and select Links and href, for example:

(Invoke-WebRequest -Uri "http://www.scriptingguys.com").Links.Href

Comments (1)

  1. josefismael says:

    don’t forget that invoke-webrequest has wget and curl as aliases, and utilizes a lot of similar switches from back in the bash days 🙂

Skip to main content