# How to access the "top level" .RSSlink from a post?

**URL:** <https://discourse.gohugo.io/t/how-to-access-the-top-level-rsslink-from-a-post/2044>\
**Category:** support\
**Created:** [November 7, 2015, 1:36am UTC](https://discourse.gohugo.io/t/how-to-access-the-top-level-rsslink-from-a-post/2044 "2015-11-07T01:36:03Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ssylvan](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/ssylvan/32/4411_2.png) [@ssylvan](https://discourse.gohugo.io/u/ssylvan)\
**Post date:** [November 7, 2015, 1:36am UTC](https://discourse.gohugo.io/t/how-to-access-the-top-level-rsslink-from-a-post/2044/1 "2015-11-07T01:36:03Z")

</div>

So my theme has an RSS section that just spits out .RSSlink in the href property. However, this obviously doesn’t work for posts since they don’t haven an rss file.

I’d really like to just always use the toplevel “root” RSSlink no matter what page is being generated, but I can’t figure out how to access it . I thought $.RSSlink would do it, but no dice. I ended up just hardcoding it to {{.Site.BaseURL}}index.xml but that seems a bit sketchy. Is there a better way?

---

<div class="post-metadata">

**Author:** ![moorereason](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/moorereason/32/592_2.png) [@moorereason](https://discourse.gohugo.io/u/moorereason)\
**Post date:** [November 10, 2015, 10:01pm UTC](https://discourse.gohugo.io/t/how-to-access-the-top-level-rsslink-from-a-post/2044/2 "2015-11-10T22:01:35Z")

</div>

The way you’ve solved it is probably the only way to do it. The root/homepage Node has an `RSSLink`, but I don’t know how you would get at that from any normal Page.

What we really need is the main `RSSLink` to be a part of the SiteInfo.

---

<div class="post-metadata">

**Author:** ![moorereason](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/moorereason/32/592_2.png) [@moorereason](https://discourse.gohugo.io/u/moorereason)\
**Post date:** [November 12, 2015, 5:27pm UTC](https://discourse.gohugo.io/t/how-to-access-the-top-level-rsslink-from-a-post/2044/3 "2015-11-12T17:27:09Z")

</div>

Created a pull request to add this feature. We’ll see if it gets merged.

> <https://github.com/gohugoio/hugo/pull/1566>

---

<div class="post-metadata">

**Author:** ![moorereason](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/moorereason/32/592_2.png) [@moorereason](https://discourse.gohugo.io/u/moorereason)\
**Post date:** [November 20, 2015, 11:40pm UTC](https://discourse.gohugo.io/t/how-to-access-the-top-level-rsslink-from-a-post/2044/4 "2015-11-20T23:40:17Z")

</div>

My pull request was merged. This feature should be in the upcoming 0.15 release.
