# Problems by accessing http static path

**URL:** <https://discourse.nodered.org/t/problems-by-accessing-http-static-path/40121>\
**Category:** General\
**Created:** [31 January 2021 16:57 UTC](https://discourse.nodered.org/t/problems-by-accessing-http-static-path/40121 "2021-01-31T16:57:59Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ChristianM](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/christianm/32/36266_2.png) [@ChristianM](https://discourse.nodered.org/u/ChristianM)\
**Post date:** [31 January 2021 16:57 UTC](https://discourse.nodered.org/t/problems-by-accessing-http-static-path/40121/1 "2021-01-31T16:57:59Z")

</div>

Hi Guys,

I really tried to find the solution to my problem myself, but for some reason I do not understand what could possibly my problem.  
So what I added to **settings.js**  
httpStatic: '/home/christian/nodered/public/'  
Restarted node-red for sure and also tried different folders till now, none with success working.

My aim is to access a subfolder e.g. '/home/christian/nodered/public/birdbox/' where I've located some images:

tying to access from the same machine (used in a template as image source):  
[http://localhost:1880/birdbox/image.jpg](http://localhost:1880/birdbox/image.jpg)  
[http://localhost:1880/public/birdbox/image.jpg](http://localhost:1880/public/birdbox/image.jpg)  
does not work for me.

via Machine IP from another machine, which should also work:  
[http://192.168.0.11:1880/birdbox/image.jpg](http://192.168.0.11:1880/birdbox/image.jpg)  
[http://192.168.0.11:1880/public/birdbox/image.jpg](http://192.168.0.11:1880/public/birdbox/image.jpg)  
gives "Cannot GET /birdbox/image.jpg" as response.

I am really somehow stuck on that because it seems that I have troubles by using the httpStatic folder, which should be a straightforward task.

Thanks for any advice,  
best regards Christian

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [31 January 2021 17:12 UTC](https://discourse.nodered.org/t/problems-by-accessing-http-static-path/40121/2 "2021-01-31T17:12:49Z")

</div>

Can you post an excerpt of your settings.js around the line you have changed please.

Are you sure you did not mean to use '/home/christian/.node-red/public/'?

**[Edit]** Also stop node-red and restart it in a terminal. The startup log will show you how httpstatic is configured.

---

<div class="post-metadata">

**Author:** ![ChristianM](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/christianm/32/36266_2.png) [@ChristianM](https://discourse.nodered.org/u/ChristianM)\
**Post date:** [31 January 2021 17:31 UTC](https://discourse.nodered.org/t/problems-by-accessing-http-static-path/40121/3 "2021-01-31T17:31:20Z")

</div>

> [@Colin](#):
>
> The startup log will show you how httpstatic is configured.

Ok, thanks so much Colin!  
I was not aware of that - somehow I managed to modify another settings.js of node-red stored somewhere else in the system.  
Since I was not using the start function, I was not aware of using the wrong settings file.  
I modified the correct settings.js and then saw the correct path when starting node-red again.

Thats it, works like a charm now,  
thanks!

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [14 February 2021 17:31 UTC](https://discourse.nodered.org/t/problems-by-accessing-http-static-path/40121/4 "2021-02-14T17:31:58Z")

</div>

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