# Change meta data if tags listing

**URL:** https://discourse.gohugo.io/t/change-meta-data-if-tags-listing/13496
**Category:** support
**Created:** [August 10, 2018, 12:45pm UTC](https://discourse.gohugo.io/t/change-meta-data-if-tags-listing/13496 "2018-08-10T12:45:52Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![mcnovy](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/mcnovy/32/6625_2.png) [@mcnovy](https://discourse.gohugo.io/u/mcnovy)
#### Post date: [August 10, 2018, 12:45pm UTC](https://discourse.gohugo.io/t/change-meta-data-if-tags-listing/13496/1 "2018-08-10T12:45:52Z")

</div>

I am sorry if this is obvious, I have been trying to search for this, but I am probably searching wrong, and Hugo is still very new to me.

I have a site, and I use the 2 default taxonomies: tags and categories.

But, trying to make my site SEO friendly, I end up with 2 options as I see it (Where I would like to use both)

For the Tags listings (e.g. www.example/tags - [www.example.com/tags/cars](http://www.example.com/tags/cars)) I dont want google to index, as I have read that is bad for SEO, so I want to change my meta tag from index, to noindex,  
but how?  
The results I have found for this, is creating custom content for each tag e.g. /content/tags/cars/\_index - /content/tags/bikes/\_index

But surely, that can’t be right… right?? that would mean a whole lot of manual “labor”.

The other case is the categories, here I understand that you do want to index those, so here I need to have a custom discription for each category, can that be done in front matter, or would this also need to be done with custom/category/food/\_index

Hope someone can shed some lights on this

---

<div class="post-metadata">

### Author: ![Yudy\_Ananda](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/yudy_ananda/32/5664_2.png) [@Yudy\_Ananda](https://discourse.gohugo.io/u/Yudy_Ananda)
#### Post date: [August 10, 2018, 1:28pm UTC](https://discourse.gohugo.io/t/change-meta-data-if-tags-listing/13496/2 "2018-08-10T13:28:13Z")

</div>

In my perspective I think it’s not bad at all to let Google index your tag or category pages, especially if you have something bold like unique meta and another SEO stuff.

I’m not sure if there is better workaround but in my case I’m using [.Scratch](https://gohugo.io/functions/scratch#readout) in my tags template (layouts/tags/taxonomy.html) and then using conditional logic in meta template

for example

```auto
{{ if $.Scratch.Get "tags" }}
     <meta name="robots" content="noindex, follow" />
{{ end }}

```

the alternative and the easier way is to prevent Google crawl the tags pages via robots.txt,

Note: you have to make sure that the tags pages not appears in your sitemap

About front matter maybe you can found the answer here

> [@Handling taxonomies like a boss - update](https://discourse.gohugo.io/t/handling-taxonomies-like-a-boss-update/7719):
>
> Live view: [http://hugo-taxonomies.netlify.com/](http://hugo-taxonomies.netlify.com/) Repo: [https://github.com/guayom/hugo-taxonomies](https://github.com/guayom/hugo-taxonomies) Here you’ll find a very detailed explanation on how to use taxonomies in a HUGO site. No hackish code or intricate tricks. There is documentation on this topic, but you’ll have to search in 3 different places and some examples are missing. So it can be very confusing at times, at least it was for me. After reading this, you will be able to: Create your own taxonomies Add custom metadata to your ta…

> **[Template lookup order](https://gohugo.io/templates/lookup-order/#examples-layout-lookup-for-taxonomy-list-pages)**
>
> Hugo uses the rules below to select a template for a given page, starting from the most specific.

---

<div class="post-metadata">

### Author: ![mcnovy](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/mcnovy/32/6625_2.png) [@mcnovy](https://discourse.gohugo.io/u/mcnovy)
#### Post date: [August 11, 2018, 6:55pm UTC](https://discourse.gohugo.io/t/change-meta-data-if-tags-listing/13496/3 "2018-08-11T18:55:18Z")

</div>

Thank you for the prompt reply, and sorry for the slow answer 🙂  
I will read it again (Had found it in my search, but since it was a year old, I was hoping an easier solution would be available )
