Take the 2-minute tour ×
Web Applications Stack Exchange is a question and answer site for power users of web applications. It's 100% free, no registration required.

There's a rather large image in a Stack Overflow post that I'd like to replace with its thumbnail and a link to the full-size image.

I know Imgur generates thumbnails for its images when you upload, but since I'm not the original uploader, is there any way for me to find the thumbnail image by URL hackery or some such?

share|improve this question
    
Related Meta.SE question: Thumbnail image on Stack Overflow –  mmyers 8 hours ago

3 Answers 3

up vote 19 down vote accepted

I can't actually find it documented anywhere, but I uploaded an image and played with the "More Sizes" list:

Original

http://i.stack.imgur.com/YdJZt.jpg

I haven't included the image inline, because StackExchange would automatically scale it down. To view the original at its full size, click the link.

Large thumbnail

http://i.stack.imgur.com/YdJZtl.jpg (added an l after the image ID)

Small square

http://i.stack.imgur.com/YdJZts.jpg (added an s after the image ID)


It doesn't always handle transparency well, but "small square" is probably what you want.

Image by digitalART2, licensed under CC-BY-2.0, available here.

share|improve this answer
2  
Here's the API documentation - the ones listed above are all the available image sizes: api.imgur.com/resources_anon#image_hash –  Ciaran Jun 10 '11 at 7:01
2  
@Ciaran: All the documented ones. There are -h, -m and -b too. –  himself Jul 6 '11 at 11:44
1  
Updated link to imgur API: api.imgur.com/models/image#thumbs –  keflavich Feb 16 at 16:42

There are 6 total thumbnails that an image can be resized to. Each one is accessable by appending a single character suffix to the end of the image ID, and before the file extension.

For example, the image located at http://i.imgur.com/12345.jpg has the Medium Thumbnail located at http://i.imgur.com/12345m.jpg

The thumbnails are:

  • s = Small Square (90x90)
  • b = Big Square (160x160)
  • t = Small Thumbnail (160x160)
  • m = Medium Thumbnail (320x320)
  • l = Large Thumbnail (640x640)
  • h = Huge Thumbnail (1024x1024)

Source: Imgur API.

share|improve this answer
3  
The images you linked to are no longer available. –  Alex Aug 14 '13 at 8:06

FYI for anyone looking for the original link on imgur's API docs

http://api.imgur.com/models/image

share|improve this answer
    
This was already linked by DmitrySandalov. –  mmyers Feb 15 at 21:58

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.