Given an IMDB movie id, how do I programmatically get its poster image?

Check out http://www.imdbapi.com/, It returns Poster url in string.

For example, check http://www.imdbapi.com/?i=&t=inception and you'll get the poster address: Poster":"http://ia.media-imdb.com/images/M/MV5BMjAxMzY3NjcxNF5BMl5BanBnXkFtZTcwNTI5OTM0Mw@@._V1._SX320.jpg"

Update: Seems like the site owner had some arguments with IMDB legal staff. As mentioned in the original site, new site's address is http://www.omdbapi.com/


The best solution is to use tmdb.org :

  1. use your imdbid in this api url after find/:

    https://api.themoviedb.org/3/find/tt0111161?api_key=__YOURAPIKEY__&external_source=imdb_id

  2. Retrieve the json response and select the poster_path attribute:

    e.g. "poster_path":"/9O7gLzmreU0nGkIB6K3BsJbzvNv.jpg"

  3. Prepend this path with "http://image.tmdb.org/t/p/w150", and you will have the poster URL that you can use in an img tag :-)


omdbapi works, but I found out you cannot really use these images (because of screen scraping and they are blocked anyway if you use them in an img tag)

Tags:

Imdb