How to change url of _index.md pages / set slug for a category/taxonomy list page?

I have content/cake/_index.md

in content/cake/_index.md I put url: “/great-cakes/”

and i’ve also tried putting this in config.toml

[permalinks]
categories = “/:title”

However, the page still shows up in the sitemap with /categories/cakes/

Is there any way to change this?

If there’s no other option i could do something like create /content/great-cakes.md, and then in single.html I could write some hacky code that tests if title == great cakes, then display all the cakes. But that feels really hacky. Is there a sane way to do it?

The stuff you are doing with an _index.md and permalinks in your config are unrelated or wrong. I’d help you debug this if you have a code repository I can clone and check out.

But at the very least, make sure to read up on taxonomies, because you are missing something (I can’t tell without seeing the code).

1 Like