The Ultimate Guide to Scraping TikTok Ads for Free (2023)
In this article, we'll learn how to scrape TikTok's top ads without coding. But why do we need to scrape TikTok ads in the first place? š¤
Why might I want to scrape TikTok?
- Media Buyers: Gain insights into trends and effective strategies.
- Marketing Professionals: Data from top performing ad campaigns can help you a lot in market research.
- Business Owners: Check out popular TikTok ads to learn what works. Improve your own TikTok ads for better results in your campaigns.
- Data Enthusiasts: You can study buying behaviors using this dataset. You can check TikTok's ad numbers for a full picture of how ads work on the platform.
But is it legal āļø to extract data from TikTok ads? Letās answer this first.
Is it illegal to scrape data from TikTok?
Collecting TikTok data, including ads, is legal, but you must follow data protection and privacy laws. Important considerations include:- Purpose of Data Collection
- Personal Identifiable Information (PII)
Purpose of Data Collection
Itās important to understand the ethical use of data. You can not collect data in a way that violates the companyās terms of services or copyright ownership. For example:
- Ethical: Collecting top-performing TikTok ads for market research and analysis to understand trends and improve advertising strategies.
- Unethical: Scraping TikTok's top ads with the intent of replicating or reusing the content for unauthorized commercial purposes.
Personal Identifiable Information (PII)
You must refrain from collecting sensitive information without usersā consent. For example:
- Ethical: Collecting only non-sensitive information related to TikTok ads, such as ad content, engagement metrics, and user interactions.
- Unethical: Collecting users' personal information, such as usernames, email addresses, or any other sensitive data, without their consent.
OK so scraping TikTok ads is legal and has many vital use cases.
But why not use TikTok's official API? š
Why not use the official TikTok API?
Plus, the official API is entirely free.
Then why arenāt we using it?
The TikTok official API has 3 flaws:
- Limited access
- Rate limits
- EU ads only
Letās learn more about these limitations.
Official TikTok API Limitations
Accessing TikTok's official API isn't straightforward. You need to apply, state a valid reason, and provide a clear use case. TikTok decides whether to grant you access or not.
Even if you get access, there's another challenge. TikTok's free APIs have usage restrictions. The commercial content API allows a maximum of 600 requests per day.
These 3 major limitations make the API a useless option for us. So what other options do we have? Well we can either code a TikTok ads scraper or use a no-code solution.
How to scrape TikTok ads without coding
If you know Python, you can write code to scrape TikTok ads. I might explain TikTok data scraping using python in a future article.
There are also scripts on GitHub, but not everyone is an expert coder. Dealing with HTML, css, and javascript is not everyoneās cup of tea.
Not everyone can reverse engineer TikTok to find backend API endpoints. As you can see, itās code, not plain English.
So what if you want a more straightforward solution? Thatās where no-code scrapers enter the chat. But there are too many options. š Well Iāve got the best TikTok ads spy tool for you.
Best no-code TikTok Scraper - Lobstr.io
Key Features
- 20+ Data Attributes: This TikTok Top Ads Scraper delivers 20+ key data attributes. From ad titles and brands to costs and more, this tool provides everything you need for analysis.
- Advanced Filtering Capabilities: Zoom in on specific regions, industries, or time ranges. Refine your search based on objectives and likes. Plus you can sort data by for you, CTA, reach and other matrices.
- Lightning-Fast Extraction: Lobstr.io extracts data at 150+ ads per minute, and being cloud-based, you don't need extra computing resources for fast ad scraping.
- Schedule Feature: Automate your scraping sessions, whether it's hourly, daily, weekly, or monthly. Set it and forget it ā the tool ensures your ad data is ready for analysis whenever you need it.
- Developer-Ready API: Lobstr.io has a developer-ready API for easy integration. Connect it with your apps/scripts for efficient workflow, compatible with Python, nodejs, or any preferred language.
- Versatile Data Export Options: Select .csv files for simple analysis. Or integrate with popular platforms. Lobstr supports Google Sheets, Amazon S3, Webhooks, and SFTP.
But the real question isā¦ how much does it cost?
Pricing
Lobstrās pricing is simple and clear:- Free Plan: Extract approximately 67,000 ads per month for free.
- Premium Plan: ā¬50 per month, costing around ā¬0.06 per 1000 ads.
- Business Plan: ā¬250 per month, costing around ā¬0.04 per 1000 ads.
- Enterprise Plan: ā¬500 per month, costing around ā¬0.03 per 1000 ads.
Now letās jump to the fun partā¦ scraping TikTok top ads without writing a single line of code.
How to scrape TikTok top ads with lobstr.io - Step by step tutorial
Alright, letās get started! Weāre going to do it in 5 simple steps:
- Step 1 - Create a Squid
- Step 2 - Add Task(s)
- Step 3 - Update Settings
- Step 4 - Launch
- Step 5 - Enjoy
Iāll be using a relevant real-life example to help you understand the process better. Weāll scrape top ads for āiPhone casesā in the US.
Letās go š
Step 1 - Create a Squid
First, make sure you have an active account on Lobstr.io. Donāt have one yet? What are you waiting for? š§ I mentioned we have a free forever plan. Go sign up right now. šAfter signing up, find the "create new squid" button on the dashboard. Click it, search for "TikTok," choose "TikTok Top Ads Scraper," and congratulations, your squid is now ready.
Step 2: Add Tasks
Next step is to add tasks. Weāll add the keyword or brand name weāve targeted. You can also add hashtags. But what if we have 100 brands or keywords? š¤
Adding tasks in bulk that too manually can be time consuming. In this case, we can use the āUpload Fileā option. This allows you to upload a file full of tasks in a second.
You can upload a file full of keywords and brand names in txt, csv, or tsv format. Make sure youāve at least 1 column named ākeywordā.
Suppose, I sell iPhone Cases online, shipping them all across the USA. How can I see what type of ads performed well on TikTok related to my niche?
Iāll enter all relevant keywords in the scraper. For this task, Iām adding keywords like: iPhone Case, customized iPhone Cases in the tasks.
Once youāve added all tasks, click the āsaveā button to move to settings parts.
Step 3 - Settings
Letās start with the basic settings. Firstly, youāll see options similar to TikTok's Top Ads Dashboard. Choose your preferred region, industry, goal, likes, time range, and sorting order.
In my case, I aim to extract ads from the USA within the last 30 days. I'm targeting the top 20% based on likes count, sorted by reach.
Then youāll see the āWhen to end runā option. This is where you specify when the scraping should stop.
How does āwhen to end runā work?
In the āwhen to end runā setting, we have 2 options.
- End run once no credit left
- End run once all tasks consumed
The first option i.e. āEnd run once no credits leftā ends the run once youāve consumed all your daily credits. This is best for getting fresh data.
If you have limited keywords, this option is perfect for you. The scraper will fetch fresh ads from those keywords every time it runs.
For example, if youāre on a free account, you have 15 minutes of execution time daily. With up to 150 ads collected per minute, extract around 2200+ ads per day, and the run will end.
The second option is āEnd run once all tasks completeā. If you have 100s of keywords and want to scrape ad data from all, this option is best for you.
It pauses the run when you consume all your daily credits, and resumes it next day when credits refill.
Suppose you have a list of 500 keywords and youāre on the free plan. At a speed of 150 results per minute, itāll scrape 2k+ results on the first day and pause the job.
When your credits refill, itāll resume the job and again scrape 2k+ ads the next day.
Since Iāve less than 1000 ads to scrape, Iāll leave this option as it is.
After selecting this preference, weāll move to the advanced settings. Here we can set concurrency, and deal with duplicate results. Hereās how it works:
The first option is concurrency. It means number of bots deployed per run. More concurrency equals faster scraping.
To remove duplicated results by toggling āUnique Resultsā. To make the output file Excel-friendly by removing the line breaks.
Iām using a free account, so the concurrency in my case will remain 1. Because you canāt increase concurrency in the free plan.
After adjusting settings, click save, then go to notifications. Turn on "on success" for successful run alerts and opt for error notifications if it stops.
After setting notifications, click save and move to the final step.
Step 4 - Launch
Now, let's launch our tool š to fetch that valuable data. You can do it manually by clicking "Save and Extract," or use the schedule feature. Here's how it works.
Letās say you want to spy on your competitor brands or an industry leaderās ads. You want to track which ads performed best for them every week or month.
In my case, Iām tracking ads within a 30 day time range, so Iād like to schedule this squid to run on the 30th day of every month.
Letās launch our beastā¦ š
Step 5 - Enjoy
Once you've launched the scraper, it'll start collecting ads data.
You can keep looking at the hot console or close the tab and do some other work. It will notify you once the run completes successfully.
To access data, you can either view it in the results tab or download the csv file. Oh, did I tell you how to export it to a 3rd party service like Google Sheets?
It's easy. Click the "delivery" icon on the top right and configure your preferred service.
Let's see what our boi fetched for me. Here goes the Excel snapshot of our data:
That's it. It was this simple to extract top ads from TikTok Top ads dashboard. Give it a try for Free. Let me answer some questions you may still have in your mind.
FAQs
Can I download the results as JSON?
This tool only supports exporting results to csv. But, you can convert csv to JSON using this website.Can I download TikTok videos using this scraper?
TikTok top ads scraper extracts data for you to study ad performance. Itās not a TikTok video downloader.
Can I use Selenium to scrape TikTok data
Yes, you can use Selenium automation, but it's not as efficient as ready-made scrapers like lobstr.io. Itās slow and needs more resources.
If you want a step-by-step tutorial, let us know through live chat or submit your idea here.What are the limitations of this scraping tool?
Till now, I havenāt encountered no limitation. You can push it to the limits to find out more. Do give us your feedback.
Can I scrape TikTok profiles using this scraper?
This tool scrapes TikTok top ads data only. If you want to scrape user profiles of TikTok users, you can share your idea here.Conclusion
So, this was my step-by-step guide on scraping TikTok ads. Lobstr.io simplifies scraping TikTok ads without coding, making it easy for all users.Not convinced yet? Give the free forever plan a shot ā no trials, no credit card needed. Use it until you're ready to join the Lobstr family.Self-proclaimed Head of Content @ lobstr.io. I write all those awesome how-tos, listicles, and (they deserve) troll our competitors.