PowerShell: Web hosted Image Scraping

Hello Guys,

In my previous post we mimicked the latest Technology of Xerox using Powershell to Extract Text from an Locally saved Image (On your machine). But today we’ll see how to do some web scrapping from Images hosted on websites, using the Image URL.

I was going through MVP, Doug Finke’s GitHub gist and found a function Get-Snoverism and I thought why not use it with my Get-ImageText Function to extract Text from the web hosted Images


So lets break this into a  3 step process.

  1. Target a website and Look for Images using the Invoke-WebRequest Cmdlet1

    This is the Image where this URL leads us –


  2. Extract the Text from the Image  using Get-ImageText Function that I’ve shared with you guys in my previous post, but with some modifications, in order to accept URL as Input instead of a local File.2
  3. Use text you’ve extracted. You can now Translate the Text in desired Language, PrintEmail and Save it as a document using Powershell .3




I’ve customized my Get-Image Function a bit and fed the Image URL to it instead of path of the locally saved Image. Following is an Animation how to run it.

ezgif.com-video-to-gif (2)


Click here to go to my GitHub Gist for the complete script.


You would need Subscription key for Microsoft optical Recognition API and ClientID and Client_secret for Microsoft Bing Translation API, please follow below links to get an idea how to obtain these keys.

Microsoft OCR API
Microsoft Translator Services

Happy reading!



2 thoughts on “PowerShell: Web hosted Image Scraping

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s