# Absolute\_url bug

**URL:** <https://talk.jekyllrb.com/t/absolute-url-bug/7491>\
**Category:** Help\
**Created:** [July 14, 2022, 6:01pm UTC](https://talk.jekyllrb.com/t/absolute-url-bug/7491 "2022-07-14T18:01:20Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ceceomer](https://avatars.discourse-cdn.com/v4/letter/c/8c91f0/32.png) [@ceceomer](https://talk.jekyllrb.com/u/ceceomer)\
**Post date:** [July 14, 2022, 6:01pm UTC](https://talk.jekyllrb.com/t/absolute-url-bug/7491/1 "2022-07-14T18:01:20Z")

</div>

It is working on local fine, but when i publish it on github it is not working.

```auto
<a class="navbar-brand" href="{{ '' | absolute_url }}">{{ site.title }}</a>

```

it gives us site url under local host, but on github it gives page url. my blog is [omercece.com](http://omercece.com), you can check it out. I use latest version of jekyll

Thanks

---

<div class="post-metadata">

**Author:** ![chuckhoupt](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/chuckhoupt/32/523_2.png) [@chuckhoupt](https://talk.jekyllrb.com/u/chuckhoupt)\
**Post date:** [July 14, 2022, 7:17pm UTC](https://talk.jekyllrb.com/t/absolute-url-bug/7491/2 "2022-07-14T19:17:19Z")

</div>

`absolute_url` combines `site.url` and `site.baseurl` with the path (the empty string in this case). Is it possible that `url` is not set in `_config.yml`? Setting `url` is required for `absolute_url` to work.

Note that the path should not be the empty string, but instead the root path: ‘/’ since you want a link to the root of your site.

Additionally, I think it is unnecessary to use `absolute_url`, since `relative_url` will work just fine (the browser will supply the rest of the URL). The `absolute_url` filter is only needed in special cases, like displaying a human-readable absolute URL, etc.

---

<div class="post-metadata">

**Author:** ![ceceomer](https://avatars.discourse-cdn.com/v4/letter/c/8c91f0/32.png) [@ceceomer](https://talk.jekyllrb.com/u/ceceomer)\
**Post date:** [July 14, 2022, 10:13pm UTC](https://talk.jekyllrb.com/t/absolute-url-bug/7491/3 "2022-07-14T22:13:47Z")

</div>

I’m new on Jekyll, i’ve seen this "url-pretty: “[omercece.com](http://omercece.com)” in \_config then though it is the right place. thanks.
