Automated YouTube Channel Performance Tracker & Data Historian
detail.loadingPreview
Automatically collect, store, and analyze detailed performance data for YouTube channels in a PostgreSQL database. This workflow efficiently tracks new video releases, captures vital statistics like views, likes, and comments, and filters out short-form content to focus on core video performance.
About This Workflow
This robust n8n workflow creates a powerful, self-updating data pipeline for YouTube channel analytics. Designed for efficiency, it intelligently identifies and fetches only new videos published since its last run for a list of specified channels. For each detected video, it gathers comprehensive statistics including view count, like count, comment count, and publish time, then stores this invaluable data in a PostgreSQL database. The workflow also incorporates smart filtering to exclude YouTube Shorts, ensuring your analytics focus on long-form content. An included advanced PostgreSQL query further enables sophisticated reporting, such as calculating representative average views by strategically excluding statistical outliers from your channel data.
Key Features
- Automated YouTube Data Collection: Continuously monitors a list of YouTube channels, automatically fetching new video releases and their associated metrics.
- Incremental Data Sync: Optimizes resource usage by only retrieving videos published after the last recorded entry for each channel, ensuring your database stays up-to-date efficiently.
- Detailed Video Statistics: Captures crucial performance indicators like view count, like count, comment count, and publish time for in-depth analysis.
- Smart Content Filtering: Automatically identifies and filters out YouTube Shorts based on video duration, providing cleaner data for traditional video performance metrics.
- Robust PostgreSQL Integration: Seamlessly stores all collected video data and channel insights into a PostgreSQL database for persistent storage, historical tracking, and advanced custom querying.
- Advanced Performance Analytics: Includes a sophisticated PostgreSQL query designed to calculate more accurate average channel views by intelligently excluding top/bottom performing outlier videos.
How To Use
- Set up Credentials: Ensure you have configured your YouTube OAuth2 API credentials (for the
get_videosnode), a Google API Key (forfind_video_data1for detailed video info), and PostgreSQL credentials for database access. - Database Initialization (One-time): Run the
create_tablePostgreSQL node once to set up thevideo_statisticstable in your PostgreSQL database. This only needs to be done once. - Provide Channel IDs: The workflow processes channel IDs in batches. Provide a list of YouTube Channel IDs as input to the
Loop Over Itemsnode. This input can come from a preceding node (e.g., a Google Sheet, another database query, or a manual trigger with structured data). - Configure Incremental Fetch: The
get_videosnode automatically looks up thelatest_publish_timefor each channel from your database to fetch only newer videos. You can adjust the default 'publishedAfter' fallback (currently 3 months) if no prior data exists for a channel. - Review Shorts Filtering: The
remove_shortscode node filters videos based on duration. Review and customize its JavaScript logic if your definition of a 'short' differs or if you wish to include all video types. - Activate & Schedule: After successfully testing, activate the workflow and set up a recurring schedule (e.g., daily or weekly) using n8n's built-in scheduling features, or trigger it via an external webhook if integrated into a larger system.
Apps Used
Workflow JSON
{
"id": "5d3ebe4c-f5ed-45bd-9d40-109e8da6732a",
"name": "Automated YouTube Channel Performance Tracker & Data Historian",
"nodes": 21,
"category": "Marketing",
"status": "active",
"version": "1.0.0"
}Note: This is a sample preview. The full workflow JSON contains node configurations, credentials placeholders, and execution logic.
Get This Workflow
ID: 5d3ebe4c-f5ed...
About the Author
Free n8n Workflows Official
System Admin
The official repository for verified enterprise-grade workflows.
Statistics
Related Workflows
Discover more workflows you might like
WhatsApp AI Assistant: LLaMA 4 & Google Search for Real-Time Insights
Instantly deploy a smart AI assistant on WhatsApp, powered by Groq's lightning-fast LLaMA 4 model. This workflow enables real-time conversations, remembers context, and provides up-to-date answers by integrating live Google Search results.
AI-Powered On-Page SEO Audit & Report Automation
Instantly generate comprehensive on-page SEO technical and content audits for any website URL. This AI-powered workflow automates the entire process, from scraping the page to delivering a detailed report directly to your inbox, empowering you to optimize for better search rankings and user engagement.
Automated AI Motion Illustration Workflow with Midjourney and Kling
Unleash your creativity with this n8n workflow that automates the generation of stunning motion illustrations. It leverages the power of Midjourney for static image creation and Kling AI to transform them into dynamic videos, all managed through the PiAPI. Perfect for content creators, marketers, and social media professionals looking to produce engaging visuals at scale.