Display All Blogs on One Page

Topic summary

A Shopify store owner wants to display articles from multiple blogs on a single page, while maintaining separate blogs for different product line landing pages. The default theme only allows displaying articles from one blog at a time.

Initial Suggestion:

  • Use a single main blog with tags to categorize articles
  • Add category navigation using Liquid code in the theme’s main-blog.liquid file

Problem:
This approach doesn’t work because separate blogs are needed for individual product line landing pages that should only show relevant articles.

Final Solution:
Create a custom Liquid section (section-blog-join.liquid) that:

  • Pulls articles from multiple selected blogs simultaneously
  • Filters articles by specific tags
  • Controls the number of displayed articles
  • Can be configured per landing page through the theme editor

The solution includes complete code for the custom section with CSS styling, Liquid templating logic to merge articles from different blogs, and a schema for theme customization settings. This allows filtering by tags while maintaining the separate blog structure needed for product-specific landing pages.

Summarized with AI on November 2. AI used: claude-sonnet-4-5-20250929.

I have quite a few articles under different blogs, and on my website blog page I would like to display ALL my blog articles with different blog categories. How can I achieve that? I can do customize coding.
https://tmgindustrial.ca/blogs/news

By default, the theme only allows me fetch blog articles under one blog category.

Help is appreciated! Thanks in advance.

Hi @tmg1101 .

One solution would be do one main Blog and use Tags in each Blog Article:

  • Create your blog articles as normal - Tag each article with your desired category.
  • You can add multiple tags per article.
  • Add Category Navigation:
    • Go to Online Store > Themes > Edit Code - Open Sections folder - Find main-blog.liquid (Dawn Theme)
    • Add a similar code to create a category menu. In your case, perhaps before
      .
{%- if blog.all_tags.size > 0 -%}
  
    

      - All
      

      {%- for tag in blog.all_tags -%}
        - {{ tag }}
        
      {%- endfor -%}
    

  

{%- endif -%}

Hi there, thanks for replying!

The reason we are having multiple blogs is because there are a few landing pages for our product lines. And on each of the landing pages we only want to display the blog articles that are related to the product line.

So in this case I can’t just put all blogs under one blog. But is there anyway to fetch blog articles by specific tags?

@tmg1101

Yes, it’s totally possible to handle this use case! You can create a custom section that allows you to:

  • Select which blogs you want to pull from (up to however many blogs you want… I did two for simplicity)
  • Filter articles by specific tags
  • Control how many articles appear

To implement this:

  • Create a new section file (e.g., ‘section-blog-join.liquid’)
  • Add it to your page template
  • In the theme editor, you can then select the blogs and tag for each landing page

section-blog-join.liquid would look like this.
style.css (basic styling)


html + liquid


  {% assign post_limit = section.settings.posts_limit | default: 3 %}
  {% assign all_articles = '' | split: '' %}
  
  {% if section.settings.blog_1 != blank %}
    {% assign all_articles = all_articles | concat: blogs[section.settings.blog_1].articles %}
  {% endif %}
  
  {% if section.settings.blog_2 != blank and section.settings.blog_2 != section.settings.blog_1 %}
    {% assign all_articles = all_articles | concat: blogs[section.settings.blog_2].articles %}
  {% endif %}

  

    {% assign shown_articles = 0 %}
    {% for article in all_articles %}
      {% if section.settings.tags == blank or article.tags contains section.settings.tags %}
        {% if shown_articles < post_limit %}
          {% assign shown_articles = shown_articles | plus: 1 %}
          

            {% if article.image %}
              
                {{ article.image | image_url: width: 400 | image_tag }}
              
            {% endif %}
            

              ### {{ article.title }}
              
              {% if article.excerpt != blank %}
                

{{ article.excerpt | strip_html | truncatewords: 30 }}

              {% endif %}
              Read more
            

          

        {% endif %}
      {% endif %}
    {% endfor %}
    
    {% if section.settings.tags != blank and shown_articles == 0 %}
      

No articles found with the tag "{{ section.settings.tags }}"

    {% endif %}
  

schema

{% schema %}
{
  "name": "Blog Posts Join",
  "settings": [
    {
      "type": "blog",
      "id": "blog_1",
      "label": "Select First Blog"
    },
    {
      "type": "blog",
      "id": "blog_2",
      "label": "Select Second Blog (Optional)"
    },
    {
      "type": "text",
      "id": "tags",
      "label": "Filter by tag",
      "info": "Enter the exact tag name (case sensitive)."
    },
    {
      "type": "range",
      "id": "posts_limit",
      "min": 1,
      "max": 3,
      "step": 1,
      "label": "Number of posts",
      "default": 3
    }
  ],
  "presets": [
    {
      "name": "Blog Posts Join",
      "category": "Blog"
    }
  ]
}
{% endschema %}