Yahoo Financial Historical Prices
I created a Jupyter notebook for downloading AAPL historical prices due to recent changes in the Yahoo Finance website. The notebook can be download here or viewed online at GitHub.
Yahoo how requires a cookie and a crumb inorder to download historical price data. The pair will work for multiple calls. After surveying existing techniques, I combined the results into the notebook.
The preliminary webpage provides the cookie and the crumb. The cookie is labeled ‘B’ and is delivery in the HTTP header. The crumb is labeled ‘Crumbstore’ and is delivered in the contents of the webpage. Sometimes the crumb contains unicode encoded characters which must be converted.
The download request uses the crumb in the URL, while the cookie is set in the HTTP header.