# Hiding post from the home page

**URL:** <https://forum.ghost.org/t/hiding-post-from-the-home-page/38604>\
**Category:** Developer help\
**Created:** [May 22, 2023, 10:15am UTC](https://forum.ghost.org/t/hiding-post-from-the-home-page/38604 "2023-05-22T10:15:19Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![IvanM](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/ivanm/32/24515_2.png) [@IvanM](https://forum.ghost.org/u/IvanM)\
**Post date:** [May 22, 2023, 10:15am UTC](https://forum.ghost.org/t/hiding-post-from-the-home-page/38604/1 "2023-05-22T10:15:19Z")

</div>

I need a routes code so I can with internal hashtag #hide to hide post only from the homepage, but the post need to be visible and readable in Tag page (for example [mydomain.com/news/](http://mydomain.com/news/)) for example.

I have managed not to be visible on homepage, but when I try to open it from tag page (for example [mydomain.com/news/](http://mydomain.com/news/)) got 404 error.

---

<div class="post-metadata">

**Author:** ![new](https://avatars.discourse-cdn.com/v4/letter/n/c6cbf5/32.png) [@new](https://forum.ghost.org/u/new)\
**Post date:** [May 22, 2023, 1:39pm UTC](https://forum.ghost.org/t/hiding-post-from-the-home-page/38604/2 "2023-05-22T13:39:45Z")

</div>

Hey there!

Posts must have to be valid under any collection in order to have a URL and load.  
This might help you to solve the problem.  
Now, All you have to do is to keep or insert **#hide** (which will be the internal tag) and add whichever tag you want like for **news** to the post. So, the post can be visible at [mydomain.com/news/](http://mydomain.com/news/) and not homepage.

You can copy and paste the below to your dynamic routing configuration if it is default or modify accordingly.

```auto

routes:

collections:
  /:
    permalink: /{slug}/
    template: index
    filter: tag:-hash-hide

  /^/:
    permalink: /{slug}/
    template: index
    filter: tag:hash-hide

taxonomies:
  tag: /tag/{slug}/
  author: /author/{slug}/

```

Reference:

> [@Filter out posts by tag on homepage](https://forum.ghost.org/t/filter-out-posts-by-tag-on-homepage/14913/6):
>
> @pewu, the reason you get a 404 is that posts have to be in some collection in order to have a URL at all, because it’s the collection’s permalink property that determines a post’s URL. To fix it, you need to not just remove posts with your tag from the index collection, but also create a new collection that you put them in. That new collection can still have the same permalink property as the index collection if you like, but its key in the collections dictionary (which is the URL where you ca…

---

<div class="post-metadata">

**Author:** ![IvanM](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/ivanm/32/24515_2.png) [@IvanM](https://forum.ghost.org/u/IvanM)\
**Post date:** [May 23, 2023, 6:00am UTC](https://forum.ghost.org/t/hiding-post-from-the-home-page/38604/3 "2023-05-23T06:00:10Z")

</div>

Wow! Tnx! Works perfectly.
