n8nflow.net logo

TikTok Post Scraper via Keywords | Bright Data + Sheets Integration

by Shiv Gupta•Updated: Last update 3 months ago•Source: n8n.io
Loading workflow viewer...

Getting Started

šŸŽµ TikTok Post Scraper via Keywords | Bright Data + Sheets Integration

šŸ“ Workflow Description

Automatically scrapes TikTok posts based on keyword search using Bright Data API and stores comprehensive data in Google Sheets for analysis and monitoring.


šŸ”„ How It Works

This workflow operates through a simple, automated process:

  • Keyword Input: User submits search keywords through a web form
  • Data Scraping: Bright Data API searches TikTok for posts matching the keywords
  • Processing Loop: Monitors scraping progress and waits for completion
  • Data Storage: Automatically saves all extracted data to Google Sheets
  • Result Delivery: Provides comprehensive post data including metrics, user info, and media URLs

ā±ļø Setup Information

Estimated Setup Time: 10-15 minutes

This includes importing the workflow, configuring credentials, and testing the integration. Most of the process is automated once properly configured.


✨ Key Features

šŸ“ Keyword-Based Search

Search TikTok posts using specific keywords

šŸ“Š Comprehensive Data Extraction

Captures post metrics, user profiles, and media URLs

šŸ“‹ Google Sheets Integration

Automatically organizes data in spreadsheets

šŸ”„ Automated Processing

Handles scraping progress monitoring

šŸ›”ļø Reliable Scraping

Uses Bright Data's professional infrastructure

⚔ Real-time Updates

Live status monitoring and data processing


šŸ“Š Data Extracted

FieldDescriptionExample
urlTikTok post URLhttps://www.tiktok.com/@user/video/123456
post_idUnique post identifier7234567890123456789
descriptionPost caption/descriptionCheck out this amazing content! #viral
digg_countNumber of likes15400
share_countNumber of shares892
comment_countNumber of comments1250
play_countNumber of views125000
profile_usernameCreator's username@creativity_master
profile_followersCreator's follower count50000
hashtagsPost hashtags#viral #trending #fyp
create_timePost creation timestamp2025-01-15T10:30:00Z
video_urlDirect video URLhttps://video.tiktok.com/tos/...

šŸš€ Setup Instructions

Step 1: Prerequisites

  • n8n instance (self-hosted or cloud)
  • Bright Data account with TikTok scraping dataset access
  • Google account with Sheets access
  • Basic understanding of n8n workflows

Step 2: Import Workflow

  1. Copy the provided JSON workflow code
  2. In n8n: Go to Workflows → + Add workflow → Import from JSON
  3. Paste the JSON code and click Import
  4. The workflow will appear in your n8n interface

Step 3: Configure Bright Data

  1. In n8n: Navigate to Credentials → + Add credential → Bright Data API
  2. Enter your Bright Data API credentials
  3. Test the connection to ensure it's working
  4. Update the workflow nodes with your dataset ID: gd_lu702nij2f790tmv9h
  5. Replace BRIGHT_DATA_API_KEY with your actual API key

Step 4: Configure Google Sheets

  1. Create a new Google Sheet or use an existing one
  2. Copy the Sheet ID from the URL
  3. In n8n: Credentials → + Add credential → Google Sheets OAuth2 API
  4. Complete OAuth setup and test connection
  5. Update the Google Sheets node with your Sheet ID
  6. Ensure the sheet has a tab named "Tiktok by keyword"

Step 5: Test the Workflow

  1. Activate the workflow using the toggle switch
  2. Access the form trigger URL to submit a test keyword
  3. Monitor the workflow execution in n8n
  4. Verify data appears in your Google Sheet
  5. Check that all fields are populated correctly

āš™ļø Configuration Details

Bright Data API Settings

  • Dataset ID: gd_lu702nij2f790tmv9h
  • Discovery Type: discover_new
  • Search Method: keyword
  • Results per Input: 2 posts per keyword
  • Include Errors: true

Workflow Parameters

  • Wait Time: 1 minute between status checks
  • Status Check: Monitors until scraping is complete
  • Data Format: JSON response from Bright Data
  • Error Handling: Automatic retry on incomplete scraping

šŸ“‹ Usage Guide

Running the Workflow

  1. Access the form trigger URL provided by n8n
  2. Enter your desired keyword (e.g., "viral dance", "cooking tips")
  3. Submit the form to start the scraping process
  4. Wait for the workflow to complete (typically 2-5 minutes)
  5. Check your Google Sheet for the extracted data

Best Practices

  • Use specific, relevant keywords for better results
  • Monitor your Bright Data usage to stay within limits
  • Regularly backup your Google Sheets data
  • Test with simple keywords before complex searches
  • Review extracted data for accuracy and completeness

šŸ”§ Troubleshooting

Common Issues

🚨 Scraping Not Starting

  • Verify Bright Data API credentials are correct
  • Check dataset ID matches your account
  • Ensure sufficient credits in Bright Data account

🚨 No Data in Google Sheets

  • Confirm Google Sheets credentials are authenticated
  • Verify sheet ID is correct
  • Check that the "Tiktok by keyword" tab exists

🚨 Workflow Timeout

  • Increase wait time if scraping takes longer
  • Check Bright Data dashboard for scraping status
  • Verify keyword produces available results

šŸ“ˆ Use Cases

Content Research

Research trending content and hashtags in your niche to inform your content strategy.

Competitor Analysis

Monitor competitor posts and engagement metrics to understand market trends.

Influencer Discovery

Find influencers and creators in specific topics or industries.

Market Intelligence

Gather data on trending topics, hashtags, and user engagement patterns.


šŸ”’ Security Notes

  • Keep your Bright Data API credentials secure
  • Use appropriate Google Sheets sharing permissions
  • Monitor API usage to prevent unexpected charges
  • Regularly rotate API keys for better security
  • Comply with TikTok's terms of service and data usage policies

šŸŽ‰ Ready to Use!

Your TikTok scraper is now configured and ready to extract valuable data. Start with simple keywords and gradually expand your research as you become familiar with the workflow.

Need Help? Visit the n8n community forum or check the Bright Data documentation for additional support and advanced configuration options.


For any questions or support, please contact: Email or
fill out this form