I'd like to be able to pass in a stock symbol and a date to pull in the closing price. Does anyone know of any good free api's? This is for non-commercial use if that matters.
The easiest way I know of is with the Yahoo Finance API. Here is a handy chart that shows all the options you can pass in (READ THE WHOLE POST, as it has been updated at the bottom):
http://ilmusaham.wordpress.com/tag/stock-yahoo-data/
Be aware of a few things:
1) Know the difference between unadjusted and adjusted prices. Splits will make your comparisons meaningless if you aren't careful.
2) Don't forget the effect of mergers and spin-offs. Go back far enough and you're almost sure to have nonsense. For example, think about the case of AT&T, which was bought, disappeared for awhile, and then the name was resurrected. Decades of AT&T's actual price history is now unavailable.