# RelPermalinks in RSS?

**URL:** <https://discourse.gohugo.io/t/relpermalinks-in-rss/48128>\
**Category:** support\
**Created:** [February 5, 2024, 6:24pm UTC](https://discourse.gohugo.io/t/relpermalinks-in-rss/48128 "2024-02-05T18:24:23Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![growdigital](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/growdigital/32/21180_2.png) [@growdigital](https://discourse.gohugo.io/u/growdigital)\
**Post date:** [February 5, 2024, 6:24pm UTC](https://discourse.gohugo.io/t/relpermalinks-in-rss/48128/1 "2024-02-05T18:24:23Z")

</div>

The RSS output for my dev site is fine eg `<link>http://localhost:1313/blog/240203-newsletter/</link>`

However, the RSS output for the live site appears to be rendered as a `RelPermalink` eg `<link>/blog/240203-newsletter/</link>`

Any ideas where I can start looking to fix this?

I’ve checked `package.json` to see if there’s any odd build commands, and had a look at `hugo.toml` for RSS configuration but can’t find anything obvious. And now I am scratching my head!

- Site: [hopegarden.uk](https://hopegarden.uk)
- Theme: [Bookworm](https://gethugothemes.com/products/bookworm)
- Repo: [github.com/growdigital/hopegarden.uk](https://github.com/growdigital/hopegarden.uk)
- [RSS template](https://github.com/growdigital/hopegarden.uk/blob/90b476e2261532795ad26c65c00bb29e70808481/layouts/categories/term.xml#L49)
- RSS output: [hopegarden.uk/categories/newsletter/index.xml](https://hopegarden.uk/categories/newsletter/index.xml)

---

<div class="post-metadata">

**Author:** ![bep](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/bep/32/3332_2.png) [@bep](https://discourse.gohugo.io/u/bep)\
**Post date:** [February 5, 2024, 6:36pm UTC](https://discourse.gohugo.io/t/relpermalinks-in-rss/48128/2 "2024-02-05T18:36:00Z")

</div>

> [@growdigital](#):
>
> Any ideas where I can start looking to fix this?

You need to set the baseURL in e.g. `hugo.toml` (or `config.toml`):

```auto
baseURL = "https://example.org"

```

---

<div class="post-metadata">

**Author:** ![growdigital](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/growdigital/32/21180_2.png) [@growdigital](https://discourse.gohugo.io/u/growdigital)\
**Post date:** [February 5, 2024, 7:03pm UTC](https://discourse.gohugo.io/t/relpermalinks-in-rss/48128/3 "2024-02-05T19:03:34Z")

</div>

I thought this was it for a moment, but for Forestry compatibility, the theme authors had put `hugo.toml` in the root directory _and_ in `/config/_default/hugo.toml`, and the baseURL is set in there

I moved everything in to the config `hugo.toml` and deleted the other one to see if that made a difference but still getting RelPermalinks on the RSS.

I’ll have another look at the RSS template, which I copied verbatim from this forum, to make sure I haven’t missed something.

Thank you!

Edit: just checked if `.Permalink` used elsewhere, and it is eg

```auto
<a href="{{.Permalink}}" class="d-block text-dark">
  <h4 class="fw-700 mt-4 mb-3">{{.Title}}</h4>
</a>

```

in [`layouts/author/list.html`](https://github.com/growdigital/hopegarden.uk/blob/main/themes/bookworm-hugo/layouts/author/list.html#L19) and that also renders as a RelPermalink: [https://hopegarden.uk/author/](https://hopegarden.uk/author/)

So a site-wide phenomenon, will dig deeper

---

<div class="post-metadata">

**Author:** ![growdigital](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/growdigital/32/21180_2.png) [@growdigital](https://discourse.gohugo.io/u/growdigital)\
**Post date:** [February 6, 2024, 10:44am UTC](https://discourse.gohugo.io/t/relpermalinks-in-rss/48128/4 "2024-02-06T10:44:33Z")

</div>

Found it! For some reason baseURL set to `/` in [`netlify.toml`](https://github.com/growdigital/hopegarden.uk/blob/957d467734802f81d512458473b7919758aaf9c7/netlify.toml#L8)

```auto
HUGO_BASEURL = "/"

```

Thanks for the headsup @bep 🙂

---

<div class="post-metadata">

**Author:** ![system](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/system/32/1_2.png) [@system](https://discourse.gohugo.io/u/system)\
**Post date:** [February 8, 2024, 10:44am UTC](https://discourse.gohugo.io/t/relpermalinks-in-rss/48128/5 "2024-02-08T10:44:43Z")

</div>

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.
