Different templates for nested sections?

So I want to use the nested sections feature but I don’t know if it possible to do what I want with it. I want to use one template for the main _index.md and another for the nested sections _index.md. Is this possible at the moment?

|---_index.md <- rendered by one section template
|--_index.md <- rendered by another section template

Is this possible or should I just cut my losses and restructure the site?

Currently not possible.

Thank you. Then I’ll stop banging my head against the well and restructure. :slight_smile:

Thanks for the great work with Hugo.

I will add that this will be possible at some point, but I did not want to add some half-baked solution before I saw nested sections used in the wild. At the very least we will support the layout = somelayout in front matter for sections pretty soon …

1 Like

Is this in addition to:


? So like /layouts/<SECTION>/somelayout.html ? Instead of having to do type and then layout?

It is what I say, nothing more, nothing less.


I met this exact same issue in my project and I was wondering if they were any news about that feature.

Not yet.

But there is a way. See:

1 Like