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

mlazuardy's avatar

[ErrorException] symlink() has been disabled for security reasons

i cant use php artisan storage:link through SSH to create symbolic link its show

  [ErrorException]
  symlink() has been disabled for security reasons

whats wrong with it? i use shared hosting

0 likes
15 replies
wilburpowery's avatar

Laravel is recommended to be used with a VPN, where you have full control over your server. All I can think of is that you don't have enough permissions to create a symbolic link on that shared server.

wilburpowery's avatar

I take it that at the moment your using the local disk in the storage options. I think you might be able to get it working using Amazon S3 or similar because you would not be required to create the symbolic link to access the files in your /public/storage directory.

wilburpowery's avatar

I can't think of another way really. A VPN is really not that expensive. You can get one on linode or DigitalOcean for like 5$/month

Snapey's avatar

Just store your files in the public folder as it is done on most of the sites on the web (e.g., every wordpress install)

Snapey's avatar

put the files directly in public folder instead of storage

I assume because you are trying to create a symlink you are putting files in storage/app/public?

mlazuardy's avatar

so i move the storage/app/public to public_html/storage/app/public? whats folder to start moving sir? can you give me an example @Snapey

mlazuardy's avatar

because i separated the public folder and rename, i just copy the content of public and move to public_html, where another laravel file is store in ..outside public_html @Snapey

Snapey's avatar
Snapey
Best Answer
Level 122

You asked how to create symlink. Your hosting provider won't let you. I suggest you write the files that you would have put in the symlink folder, instead direct in the public area of the site so that a symlink is not required.

mlazuardy's avatar

yes you right, i close this problem sir thanks

rajeshisnepali's avatar

By the way I think it is not a VPN. It's VPS (Virtual Private Server) 😂️😂️

1 like

Please or to participate in this conversation.