# Understanding .GetRemote

**URL:** <https://discourse.gohugo.io/t/understanding-getremote/38026>\
**Category:** support\
**Created:** [April 4, 2022, 9:48am UTC](https://discourse.gohugo.io/t/understanding-getremote/38026 "2022-04-04T09:48:06Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![davidsneighbour](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/davidsneighbour/32/24507_2.png) [@davidsneighbour](https://discourse.gohugo.io/u/davidsneighbour)\
**Post date:** [April 4, 2022, 11:52am UTC](https://discourse.gohugo.io/t/understanding-getremote/38026/2 "2022-04-04T11:52:09Z")

</div>

That’s two things, that’s why the docs are not clear on this. They are clear on each of these things but not both together. I remembered there was a post about how to achieve that and I knew it would come back and have some notes. Have a look and see if that helps you.

```nohighlight
{{ $img := resources.GetRemote "REMOTE_URL_TO_IMAGE" }}
{{ $img := $img.Content | resources.FromString "images/FILENAME.EXT" }}
<img src="{{ $img.RelPermalink }}">

```

[via](https://discourse.gohugo.io/t/using-getremote-on-image-puts-the-resource-in-root/36397/3) and [via](https://github.com/gohugoio/hugo/issues/9313)

Edit: I just remembered, that “my” solution is for adding the remote resource under a path/link that you wish to define by yourself. Bep’s solution in the next answer is better if you don’t care about that detail.

---

_[View the full topic](https://discourse.gohugo.io/t/understanding-getremote/38026)._
