# Certain posts not showing on homepage Papermod

**URL:** <https://discourse.gohugo.io/t/certain-posts-not-showing-on-homepage-papermod/30769>\
**Category:** support\
**Created:** [January 20, 2021, 8:15pm UTC](https://discourse.gohugo.io/t/certain-posts-not-showing-on-homepage-papermod/30769 "2021-01-20T20:15:24Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![UraniumDonut](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/uraniumdonut/32/13357_2.png) [@UraniumDonut](https://discourse.gohugo.io/u/UraniumDonut)\
**Post date:** [January 20, 2021, 8:15pm UTC](https://discourse.gohugo.io/t/certain-posts-not-showing-on-homepage-papermod/30769/1 "2021-01-20T20:15:24Z")

</div>

Hey there,  
I have recently gotten around to get my hugo up and running. I am now stumped at the following issue:  
I have two “categories” (folders in content) of posts. “Info” and “Blenders”.  
Only those, which are “Blenders” get shown on my homepage. The posts in “Info” and even those at “content root” aren’t shown. Does anyone know where the issue could be?

I am using the “Papermod” theme and I have copied the files I am using to [GitHub - UraniumDonut/donutcf](https://github.com/UraniumDonut/donutcf). The Website is hosted on [http://donut.cf](http://donut.cf)

Looking forward to your answers!

---

<div class="post-metadata">

**Author:** ![Carson](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/carson/32/13122_2.png) [@Carson](https://discourse.gohugo.io/u/Carson)\
**Post date:** [January 21, 2021, 7:44am UTC](https://discourse.gohugo.io/t/certain-posts-not-showing-on-homepage-papermod/30769/2 "2021-01-21T07:44:33Z")

</div>

Info is at [here](http://donut.cf/info/)

I think you need to understand these things first:

- [home page template](https://gohugo.io/templates/homepage/)
- [list page template](https://gohugo.io/templates/lists/)
- [single page template](https://gohugo.io/templates/single-page-templates/)

---

<div class="post-metadata">

**Author:** ![UraniumDonut](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/uraniumdonut/32/13357_2.png) [@UraniumDonut](https://discourse.gohugo.io/u/UraniumDonut)\
**Post date:** [January 21, 2021, 10:07am UTC](https://discourse.gohugo.io/t/certain-posts-not-showing-on-homepage-papermod/30769/3 "2021-01-21T10:07:59Z")

</div>

Thanks for the pointers. Despite multiple hours of googling I wasn’t able to find these pages

---

<div class="post-metadata">

**Author:** ![Vladimir\_Vinarsky](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/vladimir_vinarsky/32/17003_2.png) [@Vladimir\_Vinarsky](https://discourse.gohugo.io/u/Vladimir_Vinarsky)\
**Post date:** [August 11, 2024, 10:39am UTC](https://discourse.gohugo.io/t/certain-posts-not-showing-on-homepage-papermod/30769/4 "2024-08-11T10:39:04Z")

</div>

Dear Carson,  
thank you for replying to @UraniumDonut.  
I ma struggling with the same issue, so was happy to find your post, but unfortunately the link after `Info is at here` is no longer valid:(.

I am not able to connect the information in the docs to my case. Its like getting the four Maxwell equations written on a paper and then being asked to fix a washing machine.

Can you please give me a more verbose direction?

Thanks a lot  
Vladimir Vinarsky  
_The Curious Mechanobiologist_

---

<div class="post-metadata">

**Author:** ![chrillek](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/chrillek/32/19797_2.png) [@chrillek](https://discourse.gohugo.io/u/chrillek)\
**Post date:** [August 11, 2024, 11:19am UTC](https://discourse.gohugo.io/t/certain-posts-not-showing-on-homepage-papermod/30769/5 "2024-08-11T11:19:18Z")

</div>

> [@Vladimir\_Vinarsky](#):
>
> Can you please give me a more verbose direction?

Without seeing your code that might be difficult. Instead of hijacking a four-year-old thread, you should open a new one, include a link to your repository and describe the problem(s) you have.

---

<div class="post-metadata">

**Author:** ![Vladimir\_Vinarsky](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/vladimir_vinarsky/32/17003_2.png) [@Vladimir\_Vinarsky](https://discourse.gohugo.io/u/Vladimir_Vinarsky)\
**Post date:** [August 18, 2024, 6:28am UTC](https://discourse.gohugo.io/t/certain-posts-not-showing-on-homepage-papermod/30769/6 "2024-08-18T06:28:18Z")

</div>

For others in the future,  
who find this thread:

# It’s in FAQ of PaperMod!

As of now (August 2024) this problem is addressed in FAQs of papermod link [here](https://github.com/adityatelange/hugo-PaperMod/wiki/FAQs#posts-from-only-one-foldersection-visible-on-home-page).

I copy the current info here, so you do not have to click further:

> Posts from only one folder/section visible on home page  
> That is because PaperMod uses mainsections from Hugo. Read more: [collections.Where](https://gohugo.io/functions/where/#mainsections)
> 
> If you have not set this config parameter in site config, it will default to the section with the most pages. You can customize it with:

> ```auto
> params:
> mainSections:
> - blog
> - docs
> 
> ```

# Example

To see it in real life, here is a screenshot of my hobby page (link [here](https://vladimir-vinarsky.me)):

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/gohugo/original/3X/5/4/54fc8c5dbfd117fd41a9703fc2043dc4ca1087f3.jpeg)  
Only posts from **Travel** and **Biology** appear on the homepage

# config.yaml

Here are the relevant parts of the config.yaml file:

```auto
# In your config.yaml file
params:
   mainSections: # define sections which posts appear on home page 
     - travel # posts will appear on homepage
     - biology # posts will appear on homepage
# - command_line # posts will not appear on homepage
menu:
  main:
    - identifier: travel # this corresponds to the relevant mainSection 
      name: Travel
      url: "/travel/"
      weight: 1
    - identifier: picos-de-europa # subsection of travel section (posts for one of the trips) 
      name: "Picos de Europa"
      url: "/travel/picos-de-europa/"
      parent: "travel" # being a child of "travel" will inherit the mainSection
      weight: 2
    - identifier: "command_line" # commented out in mainSection, posts will not appear
      name: "Command line"
      url: "/command_line/"
      weight: 3
    - identifier: biology # this corresponds to the relevant mainSection
      name: Biology
      url: "/biology/"
      weight: 4

```

**Notes:**

- I use the `identifier` in the menu items to define `mainSections`. The benefit is that it is unique and gives you the ability to have the same name for more menu icons.
- Including items in `mainSections` also influences the `ShowPostNavLinks` feature. If the mainSections are not set will default to displaying it on posts within sections with _highest number of posts_
- My website is developing and it may happen that it will change. If so I will re-edit the post.
- In case there is some major mistake/improvement possible, please let me know

Have a great day everyone  
**Vladimir**  
_The Curious Mechanobiologist_
