Plugin Name: YouTube Channel to Posts
Author: Konstantinos Kourentzes
Version: 1.1
Description: This plugin fetches videos from a specified YouTube channel using the YouTube Data API v3 and automatically creates WordPress posts with embedded videos, tags, and featured images.
Table of Contents
- Introduction
- How the Plugin Works
- How to Install the Plugin
- How to Set Up the Plugin
- How to Get a YouTube API Key
- How to Find Your YouTube Channel ID
- No Warranty Disclaimer
1. Introduction
The YouTube Channel to Posts plugin allows WordPress site owners to automate the process of embedding YouTube videos from a specific channel into their websites. It fetches videos using the YouTube Data API v3 and creates posts with:
- Embedded YouTube video.
- Video description.
- Video tags as post tags.
- YouTube thumbnail as the post’s featured image.
- Category: Automatically set to “Music”.
This is ideal for bloggers, content creators, and websites focused on video content.
2. How the Plugin Works
- The plugin connects to the YouTube Data API v3 using an API key you provide.
- It retrieves the most recent videos (up to 5) from the specified YouTube channel.
- For each video:
- It creates a WordPress post.
- The YouTube thumbnail becomes the post’s featured image.
- The video is embedded using an
<iframe>
in the post content. - The video description is added below the embedded video.
- Video tags are added as WordPress post tags.
- The post is assigned to the “Music” category.
- A cron job automatically checks for new videos every 2 hours, ensuring your site stays updated.
3. How to Install the Plugin
- Download the Plugin:
- Obtain the plugin ZIP file:
yt-channel-to-post.zip
.
- Obtain the plugin ZIP file:
- Upload the Plugin:
- Go to your WordPress Admin Dashboard.
- Navigate to Plugins > Add New.
- Click Upload Plugin, select the
yt-channel-to-post.zip
file, and upload.
- Activate the Plugin:
- After uploading, click Activate.
4. How to Set Up the Plugin
- Go to the WordPress Admin Dashboard.
- Navigate to Settings > YT Channel to Posts.
- Configure the following settings:
- YouTube Channel ID: Paste your YouTube Channel ID.
- YouTube API Key: Enter the API Key you generated.
- Placeholder Image (Optional): Add a default image URL if thumbnails are unavailable.
- Click Save Changes.
- Manually Fetch Videos:
- On the settings page, click Fetch New Videos to test the plugin immediately.
5. How to Get a YouTube API Key
- Go to the Google Cloud Console.
- Create a new project or select an existing project.
URL: https://console.developers.google.com/projectcreate - Enable the YouTube Data API v3:
- Navigate to APIs & Services > Library.
- Search for “YouTube Data API v3” and enable it.
- Create API Credentials:
- Go to APIs & Services > Credentials.
- Click Create Credentials > API Key
- Copy the generated API Key.
- Paste the API Key into the plugin settings.


6. How to Find Your YouTube Channel ID
You can find your Channel ID in one of the following ways:
- From the Channel URL:
- If your channel URL is:
https://www.youtube.com/channel/UC_x5XG1OV2P6uZZ5FSM9Ttw
,
then your Channel ID isUC_x5XG1OV2P6uZZ5FSM9Ttw
.
- If your channel URL is:
- Using YouTube Settings:
- Log in to YouTube.
- Go to YouTube Studio.
- Navigate to Settings > Advanced Settings.
- Your Channel ID will be displayed under “Channel”.
- From the Studio URL:
- go to URL studio.youtube.com

7. No Warranty Disclaimer
NO WARRANTY PROVIDED:
This plugin is provided “as is,” without warranty of any kind, express or implied. Use at your own risk. The author is not responsible for any issues, damages, or losses arising from the use of this plugin. Always back up your site before installing new plugins.
Example of How It Works
Example Video:
- Channel ID:
UC_x5XG1OV2P6uZZ5FSM9Ttw
- Video Title: “Introduction to YouTube API”
- Resulting Post:
- Title: “Introduction to YouTube API”
- Category: Music
- Tags: YouTube API, Development, Tutorial
- Featured Image: Video thumbnail.
- Content:
<iframe width="560" height="315" src="https://www.youtube.com/embed/VIDEO_ID" frameborder="0" allowfullscreen></iframe> <a href="https://www.youtube.com/watch?v=VIDEO_ID" target="_blank">Watch on YouTube</a> <p>Video description text...</p>
Final Notes
This plugin automates video content curation for your WordPress site, reducing manual effort. It’s lightweight, customizable, and works seamlessly with the YouTube Data API.
For further questions, suggestions, or contributions, feel free to contact the plugin author or leave feedback.
