Personal YouTube Channel Videos Website hosted in GitHub Pages for Free which populates content automatically.
Published: 2022-07-05 10:47:28

---
title: Personal YouTube Channel Videos Website hosted in GitHub Pages for Free which populates content automatically.
published: true
date: 2021-10-25 11:40:27 UTC
tags: 
canonical_url: https://lkgforit.com/personal-youtube-channel-videos-website-hosted-in-github-pages-for-free-which-populates-content-automatically
---

![image.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1636560455636/6baaDl9lp.png)

# YouTube Channel Website Features - YouTube Videos As Posts:

1. Free Hosting using GitHub Pages and open-source code base in GitHub.
2. It can update all the videos, title, and description available inside the channel into the website everyday automatically using the GitHub Actions feature.
3. No need to manually do any step after posting any new video in YouTube, it will be updated in website on next day.

## How to Reuse this Action Template which creates a personal website for the YouTube videos in my channel hosted in GitHub Pages using Jekyll and GitHub Actions for free!

1. Copy [this GitHub Action](https://github.com/marketplace/actions/youtube-videos-as-posts) below:

```
   - name: YouTube-Videos-As-Posts
     uses: SSanjeevi/YouTubeVideosAsPosts@Release1.0.0
     with:
     GoogleApiKey: ${{ secrets.GoogleApiKey }}
     channelName: 'channel_Name'

   - name: Commit and push update
     run: |-
     git config --global user.email "youremailid@gmail.com"
     git config --global user.name "yourUserName"
     git add -A
     git commit -m "Updated YouTube Video posts from GitHub Actions"
     git push

```

1. Here GoogleApiKey secret should contain value of Google console Api id. Refer this video to generate the Api key - [YouTube Video to get google console Api id](https://www.youtube.com/watch?v=pP4zvduVAqo) or [follow this article](https://www.slickremix.com/docs/get-api-key-for-youtube/). After getting Google API key by following above article or video - follow [this article](https://docs.github.com/en/actions/security-guides/encrypted-secrets) to update the secrets in the repo with name - GoogleApiKey.
2. Clone or use any Jekyll Theme for the repo - e.g.: i have [cloned this repo](https://github.com/wowthemesnet/jekyll-theme-memoirs) in [this website](https://chemistry.lkgforit.com/). If you need readymade repo then, Just Fork this repo: [Fork this on GitHub](https://github.com/SSanjeevi/YoutubeChannelWebsite/fork) so that you will have the pipeline and website setup with this theme as it and just update the pipeline GitHub Action with YouTube Channel name and update secret by following above steps.
3. Keep the \_posts folder empty - this Action will create all the videos as posts in the repository.
4. Enable the repo as GitHub pages - Follow [this article](https://docs.github.com/en/pages/setting-up-a-github-pages-site-with-jekyll).
5. You are ready with website with Videos embedded in GitHub Pages

Embedded the website created by following this document [here](https://lkgforit.com/videos) and the direct URL is [this](https://tv.lkgforit.com/).

Image of website:

![image.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1636560253381/HCZLrLQ8y.png)

Reference:

https://github.com/dsebastien/youtubeChannelVideosFinder

https://github.com/nathancy/jekyll-embed-video