Scrape Instagram post likes into a Google Sheet
How to scrape Instagram post likes into a Google Sheet: install the Chrome extension, click Build with Browser agent, tell the agent what you want, and follow its prompts. A working bot is built and tested in minutes.
Here is how the automation works. To scrape Instagram post likes, read the post links from a Google Sheet, open each post in a loop, click like with Click element, and scrape the handle and profile link of each user who liked it with Get data from bot's current page. Each user is written to the sheet beside the post link, and the post's row is deleted once done. Instagram shows up to 100 likes per post.
Build the Instagram likes scraper from a description
Describe it and click the button: the agent builds and tests the likes scraper in your Chrome extension. Be logged in to Instagram in the browser that runs it, which is the desktop app for your own Chrome.
- Open each Instagram post link in my sheet
- Like the post and scrape the users who liked it
- Add them to the data tab with the post link
- Delete the post link once it is done
You need a Google Sheet, named something like Instagram likes, with two tabs: links, one post URL per row, and data, empty. Leave the sheet alone while the run adds users to data and deletes post links.
The video shows the agent building the Instagram likes scraper from the lines above, in a few minutes.
Build the Instagram likes scraper step by step
The steps the agent builds, as the Builder shows them: each step by its name, with the fields to set under it. Add them yourself in this order in the step-by-step builder, or open the agent's result there to adjust it.
- 1.0
Read data from a Google SheetSpreadsheet: your sheetSheet name: links
- 2.0
Loop through data- repeats for every row in
[google-sheet-data]
- 2.1
Go to pageURL: the post link column of[google-sheet-data]
- 2.2
Click elementSelect: the post's like button
- 2.3
Get data from bot's current pageSelect: the custom selectors[role="dialog"] span divfor the handle and[role="dialog"] [role="link"]for the profile link
- 2.4
Append or merge dataData A: the post URL column of[google-sheet-data]Data B:[scrape-data]
- 2.5
Write data to a Google SheetSpreadsheet: your sheetSheet name: dataDATA:[appended-data]
- 2.6
Delete rows from a Google SheetSpreadsheet URL: your sheetSheet name: linksFirst row to delete: 1Last row to delete: 1
- repeats for every row in
Common questions about scraping Instagram post likes
Why is the like button not clicked?
Instagram's layout has changed or the selection missed. In Click element, reselect the like button on a post. When a run fails, hand it to the agent and it repairs the step.
Why are no Instagram likes scraped?
The selectors no longer match the page. In Get data from bot's current page, check the custom selectors are [role="dialog"] span div and [role="dialog"] [role="link"]. The video above walks through the setup.
Why is no data written to the Google Sheet?
DATA points at the wrong token. In Write data to a Google Sheet, set DATA to [appended-data].
How many likes can I scrape from an Instagram post?
Up to 100 per post. Instagram shows no more than that, so the scraper cannot collect more.
Can I scrape Instagram post likes without code?
Yes. Every step is a no-code step in the Chrome extension; the two selectors above are the only thing to paste, and the agent sets them for you.
Can I schedule the Instagram likes scraper?
Yes, once the automation can log in by itself. Share the cookie in the automation's settings, or add steps to log in.
How do I scrape Instagram users from a hashtag instead?
See scrape Instagram hashtag pages for handles and post links. To collect the post links for this guide first, see scrape Instagram post links for every search term, and to post to Instagram, see automate Instagram posts.
Where do I get help?
Get in touch with support, or ask in the axiom.ai community.
Related guides
Scrape Instagram post links for every search term in a Google Sheet
- Read the search terms from my Terms tab
- Search Instagram for each term
- Collect every post link on the results
- Write them to my Posts tab and delete the term
Automate Instagram posts from a Google Sheet
- Read the posts from my Instagram posts sheet
- Open Instagram and start a new post
- Upload the image and add the caption from the row
- Click Share and delete the row
Scrape Helium 10 Black Box product data into a Google Sheet
- Read the search criteria from my Google Sheet
- Enter each set into Helium 10 Black Box
- Run the search and scrape every product
- Add the products to the Products tab