A few years ago, I wrote about Google's secret screenshot API - a slightly cumbersome way to take website screenshots for free.
There's another service which you may find simpler to use - mShots from WordPress.
Here's how it works:
- Take any website link:
- URL Encode it:
- Add it to the end of this URL:
?w=800to the end:
There are a few things to note. The first time you send a URL to the service it will reply with
HTTP 307 (temporary redirect) and you'll get this image:
Wait a few seconds and request the URL again, you should now have the image.
You can change the height of the image with
h=500. For example:
You can request different widths by changing the
?w=800 to something else. The maximum image size is 1280x960. Changing the width doesn't affect the viewport, just the size of the returned image. Although, at some widths, you'll get a centre crop.
There are no other options. You can't change the image quality, image format, the IP address, geolocation, or anything else. Images will be cached for an unspecified period, so you'll need to mangle the link if you want to regenerate it.
mShots looks like it is abandonware - no new updates to it in the last 2 years. That's a shame, but you get what you pay for.