The best source of international human given (first) names comes from a German computer magazine. The text file has nearly 50k names that are classified by likely gender, and how popular in each country. It's carefully curated and has a friendly license (GNU Free Documentation License 1.2).
The file can be downloaded here : ftp://ftp.heise.de/pub/ct/listings/0717-182.zip (name_dict.txt contains the data).
Instead of parsing this file, you can use the python port SexMachine (really) - package and github repo. I'm sure other languages have their own ports. There is also a windows executable (details).
For US baby names, you can use the Social Security Admin's download (overview) and link to data. This data can be national or on the state level, and going back to the late 19th century.
To safeguard privacy, we restrict our list of names to those with at least 5 occurrences.
You'll also find ports of this data to various languages.