# Is it safe to change default routing?

**URL:** <https://forum.ghost.org/t/is-it-safe-to-change-default-routing/11296>\
**Category:** Developer help\
**Created:** [January 10, 2020, 10:00pm UTC](https://forum.ghost.org/t/is-it-safe-to-change-default-routing/11296 "2020-01-10T22:00:14Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![hooj999](https://avatars.discourse-cdn.com/v4/letter/h/85f322/32.png) [@hooj999](https://forum.ghost.org/u/hooj999)\
**Post date:** [January 10, 2020, 10:00pm UTC](https://forum.ghost.org/t/is-it-safe-to-change-default-routing/11296/1 "2020-01-10T22:00:14Z")

</div>

I would like all posts on my site to be within /posts/ as opposed to straight off the root of the site

I’m pretty new to Ghost but i’ve been reading about URLs & Dynamic Routing along with Collections. Looking at the default routes.yaml I see:

```
collections:
  /:
    permalink: /{slug}/
    template: index

```

I changed this to:

```
collections:
  /:
    permalink: /posts/{slug}/
    template: index

```

Is there any negative interaction or potential future issues with tags and pages or if I want to add further sections eg /blog? is the logic of the ‘/’ collection having /posts/ in the permalink wrong? What about sitemaps?

These seem unaffected, but just want to be sure. Now when I browse my posts, I see /posts/ in the URL and it all seems to work fine.

A key reason to want to do this is for fine grained cache settings on CDN

Any tips on best practice here would be appreciated. I don’t want to have to rely on using a ‘posts’ tag for this, but I suspect this is not necessary

Thanks in advance

---

<div class="post-metadata">

**Author:** ![vikaspotluri123](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/vikaspotluri123/32/24_2.png) [@vikaspotluri123](https://forum.ghost.org/u/vikaspotluri123)\
**Post date:** [January 12, 2020, 4:33am UTC](https://forum.ghost.org/t/is-it-safe-to-change-default-routing/11296/3 "2020-01-12T04:33:32Z")

</div>

Dynamic routing is designed exactly for a use case like yours so there’s definitely nothing wrong with that! 🙂

Just remember, if you’re looking to add more routes, the route a particular post gets is top-down (the first collection that matches the filter takes the post)

---

<div class="post-metadata">

**Author:** ![hooj999](https://avatars.discourse-cdn.com/v4/letter/h/85f322/32.png) [@hooj999](https://forum.ghost.org/u/hooj999)\
**Post date:** [January 12, 2020, 9:42am UTC](https://forum.ghost.org/t/is-it-safe-to-change-default-routing/11296/4 "2020-01-12T09:42:55Z")

</div>

Thanks (again!) for the help

So in this case I was curious becuaes I changed the ‘/’ collection to go to ‘/posts/’

From a functionality perspective, it works fine, the links updated and so did the sitemaps. No navigation problems and the site is not yet public, so I don’t need to set up any redirects so that is all good

However with the same logic, say I wanted to add /blog and /whatever; how would I set those up and would it mean that I have to always apply the ‘blog’ tag for it to take that route?

I pretty much get the collections documentation but what I am not fully sure on his how to make sure that content gets the right route as tags can be easily forgotten

---

<div class="post-metadata">

**Author:** ![vikaspotluri123](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/vikaspotluri123/32/24_2.png) [@vikaspotluri123](https://forum.ghost.org/u/vikaspotluri123)\
**Post date:** [January 12, 2020, 5:29pm UTC](https://forum.ghost.org/t/is-it-safe-to-change-default-routing/11296/5 "2020-01-12T17:29:03Z")

</div>

> [@hooj999](#):
>
> However with the same logic, say I wanted to add /blog and /whatever; how would I set those up and would it mean that I have to always apply the ‘blog’ tag for it to take that route?

Not exactly, but yes. Since the filter parameter supports logic outside of tags, you can technically create routes based on other data. However, in practice, (internal) tags tend to be used since they allow you to categorize content. The filter paramater determines what collection a post belongs to.

---

<div class="post-metadata">

**Author:** ![hooj999](https://avatars.discourse-cdn.com/v4/letter/h/85f322/32.png) [@hooj999](https://forum.ghost.org/u/hooj999)\
**Post date:** [January 13, 2020, 9:11am UTC](https://forum.ghost.org/t/is-it-safe-to-change-default-routing/11296/6 "2020-01-13T09:11:15Z")

</div>

Great! I will do a bit more reading. Internal tagging makes more sense now, think I just need to tweak a bit.
