Web Scraping a Javascript Heavy Website in Python

Using Pandas for Analysis

Megan Dibble

--

I set out to try using the Python library BeautifulSoup to get data on the retailers that would be attending a market, as shown on this webpage: https://www.americasmart.com/browse/#/exhibitor?market=23.

What I found, however, was that the BeautifulSoup function (BeautifulSoup(url, ‘html.parser’)) only returned the header and footer of the page. It turns out that this website relies on Javascript to populate most of the data on the page, so the data I was looking for was not in…

--

--

Megan Dibble

Data Journalist @ Alteryx. I mostly write about data science and career advice. Occasionally I’m funny. Find me on LinkedIn!