Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

PatrickL's avatar

Storage:Link not Working Properly

I used the storage:link artisan command to generate a symlink to my application's assets for use in the views (logos, images, etc...). However, when I load my app to a Homestead VM, the images are not showing up on my views.

For instance, when I do something like:

 <img src="{{ URL::asset('storage/images/logo.png') }}" alt = {{ config('app.name') }} height = "50" width = "50">

to link to a file in

public/storage/images/logo.png

I get nothing.

What am I doing wrong?

0 likes
10 replies
realrandyallen's avatar

Check the permissions of your storage/app/public folder and files - needs to be at least 755

petrit's avatar

If you are using windows than you have to "run as administrator" the command line editor. Than enter the "vagrant up" and "vagrant ssh" and execute the command from there and it should work.

Snapey's avatar

review what html source you can see in ypur browser

PatrickL's avatar

@SNAPEY - The resource URL looks right.

<img src="http://homestead.test/storage/images/logo.png" height = "50" width = "50">

However, when I select the resorce in the view source inspector, it says there was an error loading the resource. Apparently, the server is returning a 404 not found error.

Could this be because I am using Homestead in-project? It seemed to work fine when I was testing it in MAMP.

rumm.an's avatar

It could be because of storage link you created as a normal user, and your homestead server tries to access it as vagrant which is not allowed, I guess. Try deleting the symlink and re creating it from homestead environment.

Also make sure, that filestorage/app/public/images/logo.png exists in project folder.

1 like
rumm.an's avatar

@patrickl welcome, whenever your problem is solved, please make sure you mark it as solved. Be it any forum.

Please or to participate in this conversation.