You aren't signed in     Sign In    Help

Photo Source URLs

You can construct the source URL to a photo once you know its ID, server ID, farm ID and secret, as returned by many API methods.

The URL takes the following format:

http://farm{farm-id}.static.flickr.com/{server-id}/{id}_{secret}.jpg
	or
http://farm{farm-id}.static.flickr.com/{server-id}/{id}_{secret}_[mstb].jpg
	or
http://farm{farm-id}.static.flickr.com/{server-id}/{id}_{o-secret}_o.(jpg|gif|png)

Size Suffixes

The letter suffixes are as follows:

ssmall square 75x75
tthumbnail, 100 on longest side
msmall, 240 on longest side
-medium, 500 on longest side
blarge, 1024 on longest side (only exists for very large original images)
ooriginal image, either a jpg, gif or png, depending on source format

Note: Original photos behave a little differently. They have their own secret (called originalsecret in responses) and a variable file extension (called originalformat in responses). These values are returned via the API only when the caller has permission to view the original size (based on a user preference and various other criteria). The values are returned by the flickr.photos.getInfo method and by any method that returns a list of photos and allows an extras parameter (with a value of original_format), such as flickr.photos.search. The flickr.photos.getSizes method, as always, will return the full original URL where permissions allow.

Example

http://farm1.static.flickr.com/2/1418878_1e92283336_m.jpg

farm-id: 1
server-id: 2
photo-id: 1418878
secret: 1e92283336
size: m

Web Page URLs

URLs to photo and profile pages use either the user's NSID (the number with the '@' sign in it) or their custom URL (if they've chosen one). You can find their custom URL with a call to flickr.people.getInfo. The NSID version of the URL will always work, regardless of whether they've set up a 'pretty' URL, so you can avoid the API call by simply using the the user ID returned by most photo API calls.

You can then easily build URLs to profiles, photostreams, individual photos or photosets:

http://www.flickr.com/people/{user-id}/ - profile
http://www.flickr.com/photos/{user-id}/ - photostream
http://www.flickr.com/photos/{user-id}/{photo-id} - individual photo
http://www.flickr.com/photos/{user-id}/sets/ - all photosets
http://www.flickr.com/photos/{user-id}/sets/{photoset-id} - single photoset

Other URLs can be constructed similarly. Directing a user to http://www.flickr.com/photos/me/* or http://www.flickr.com/people/me/* will replace the 'me' with thier own user ID, if they're logged in (otherwise it will redirect to the latest photos page).

Examples

http://www.flickr.com/photos/12037949754@N01/
http://www.flickr.com/photos/12037949754@N01/155761353/
http://www.flickr.com/photos/12037949754@N01/sets/
http://www.flickr.com/photos/12037949754@N01/sets/72157594162136485/