Skip to main content
norman_2w6pz0sxy78au's profile

Thu, Nov 1, 2018 4:26 AM

How to automatically create href to imdb person knowing only "name" eg "Tom Hanks"

I am creating movie pages for my web site automatically and would like to add href in the code to imdb actors. I know the actors names but not the nconst in IMDB. So, how do I automatically create href to imdb person knowing only "name" eg "Tom Hanks"




14.1K Messages


419.3K Points

2 y ago

Hi Norman,

If you plan to use any content from IMDb, you should heed:
Content licensing
IMDb licenses content to a wide selection of businesses including movie studios, cable companies, websites, video retailers, software developers, electronics manufacturers, mobile applications, and more. We offer content licensing packages that are customized to meet your needs based on your specific audience and the data being licensed. IMDb licensing content includes: cast & crew, user ratings, plot summaries, release dates, box office, keywords, filmography credits, awards, biographies, nicknames and more.

To learn more, please contact our Licensing Department for further information.

Please see our Content Subscription Service Terms and Conditions.
IMDb prefers that you link to names in IMDb using name ID:{Name-ID}/
where {Name-ID} is of the form: nm1234578

For example:
The Name ID for Tom Hanks is nm0000158. The link for Tom Hanks is

Alternately, you can use IMDb's format for Name searches:{Name}#nm
where {Name} is the name of the person with plus signs ("+") for spaces:

For example:
This is the name search for Tom Hanks:

The down side to using IMDb Name searches is that you are not guaranteed a result and may receive multiple results.

7.7K Messages


177K Points

2 y ago

Hi, Norman. That is not something that can be easily automated without some risk of false positives. The IMDb Help article "Can I use IMDb data in my software?" should be of interest to you, as far as getting started with the most comprehensive methods of gathering information. The IMDb dataset "name.basics.tsv.gz" includes "Known For" data, which helps disambiguate separate people who have the same name. Unfortunately, in order sort information according to IMDb's proprietary popularity metric, the Advanced Name Search (ANS) would have to be used, and evaluating the actual ranking figures requires an active IMDbPro subscription.