Hi all,
I’ve been plugging away at this for days.
Here is my env:
```
hugo v0.157.0-7747abbb316b03c8f353fd3be62d5011fa883ee6+extended+withdeploy linux/amd64 BuildDate=2026-02-25T16:38:33Z VendorInfo=gohugoio
GOOS="linux"
GOARCH="amd64"
GOVERSION="go1.26.0"
github.com/webmproject/libwebp="v1.6.0"
github.com/sass/libsass="3.6.6"
I have an issue where I am trying to render images, and, they only render if I hard code the server, similar to below (please note url redacted for privacy)![]()

That renders as html correctly, on my localhost deployment as:
http://localhost:1313/knowledgebase/desktop_9880364062115507149.jpg
I have my hugo.toml set to:
baseURL = ‘http://67.xxx.xxx.xxx/knowledgebase/’ # For server deployment
baseURL = ‘http://localhost:1313/knowledgebase/’ # Default for local development
languageCode = ‘en-au’
title = ‘Redacted for privacy’
contentDir = ‘content’
enableEmoji = true
copyright = '20026 Redacted for privacy ’
[params]
[module]
[[module.imports]]
path = “github.com/colinwilson/lotusdocs”
disable = false
[[module.imports]]
path = “github.com/gohugoio/hugo-mod-bootstrap-scss/v5”
disable = false
[markup]
[markup.tableOfContents]
endLevel = 3
startLevel = 1
[markup.goldmark]
[markup.goldmark.renderer]
unsafe = true # https://jdhao.github.io/2019/12/29/hugo_html_not_shown/
[markup.goldmark.parser]
[markup.goldmark.parser.attribute]
block = true
relativeURLs = false
canonifyURLs = false
uglyURLs = false
colorScheme = “dark”
As you can see, I am using a theme for docs.
However, I need to have the images on my physical server for them to load like this.
I have tried so many variations, as shown here. Excuse how verbose it is. I was testing, trying to figure it out:
The below image has always worked:
Original with 67.xxx (renders as http://localhost:1313/knowledgebase/desktop_9880364062115507149.jpg)

Adjusted 1: (this renders as nothing)

Adjusted 2: (this renders as nothing)


So, trying a NEW image, that has never worked below:
Adjusted 1: (this renders as nothing)

Adjusted 2: (this renders as nothing)



Another image… that exists, and is not a gif, but a png:
Adjusted 1 (renders as http://localhost:1313/knowledgebase/redacted-1024x717_8183639976758262139.png)


Another image, new gif, testing if file simply broken:
Adjusted 1 (renders as nothing)

Adjusted 2 (renders as nothing)

a png in the same location
Adjusted 1 (renders as nothing)

Adjusted 2 (renders as nothing)


Adjusted 4 (renders as nothing)

What I want, is to just say something like:

…and it renders to either my localhost, or the 67.xxx.xxx.xxx server, depending on where I deploy to.
Can anyone see what is happening, and what I’m doing wrong? I’m pulling my hair out. Thank you so much! Any advice greatly appreciated.
