Post

[TEMPLATE] How to Write a Blog Post

[TEMPLATE] How to Write a Blog Post

🐸 This post teaches you how to create your own blog post.
It is a post and also a template. Copy this file to start.


🧱 1. File Naming

All posts live in _posts/
Filename must follow this format:

1
YYYY-MM-DD-title-of-post.md

📌 This post is named:
_posts/2025-07-17-template-post-guide.md


📋 2. Front Matter

This block at the top tells Jekyll/Chirpy how to display your post.

1
2
3
4
5
6
7
8
9
---
title: "My Amazing Post Title"
date: 2025-07-17 09:00:00 +1000
categories: [main-topic, optional-subtopic]
tags: [keyword1, keyword2]
pin: false
comments: true
thumbnail: /assets/img/posts/my-thumb.jpg
---

Breakdown:

FieldDescription
titleMain title
dateDate/time for ordering
categoriesPrimary category list
tagsTag keywords for search
pintrue will “stick” this post at the top
commentsEnables Giscus/Disqus/etc
thumbnailPath to image (used in previews)

🖼️ 3. Thumbnails & Images

Place images inside /assets/img/posts/

  • Thumbnails should be ~800×400 or square
  • Use web-optimized JPEG/PNG

Use Markdown for inline images:

1
![Alt text](/assets/img/posts/my-image.jpg)

To center + resize:

1
2
3
<p align="center">
  <img src="/assets/img/posts/my-image.jpg" alt="Description of image" width="400"/>
</p>

🐸 4. Markdown Content

You can use:

Headers

1
2
## This is an H2
### This is an H3

Bold, Italic, Lists

1
2
3
**bold**, *italic*, `code`
- bullet
1. numbered

Blockquotes

1
> This is a quote.

Code Blocks

```python
def frog():
    return "ribbit"
```

🔖 5. Tags & Categories

Chirpy shows:

  • Tags in the sidebar & search
  • Categories for organization (can be nested)

Use sensible lowercase tags like:

1
2
tags: [art, frogs, updates]
categories: [life, frogs]

🚀 6. Publishing

Once your post is saved to _posts/:

1
2
3
git add _posts/2025-07-17-my-post.md
git commit -m "add new post"
git push

Chirpy will auto-rebuild your site via GitHub Pages Actions.


✅ 7. Final Checklist

  • Filename is in YYYY-MM-DD-title.md format
  • Front matter exists and is valid YAML
  • At least one category and tag
  • Thumbnail is placed in /assets/img/posts/
  • Post added to _posts/ folder
  • You pushed it to GitHub

🐸 8. Example Thumbnail Display

Here’s how this post’s thumbnail might appear:

Template post thumbnail showing blog post guide


Feel free to copy this file as your starting point for each post.
Delete sections that aren’t needed—this is just a guide.

This post is licensed under CC BY 4.0 by the author.