you need to set the correct access-rights for that folder. The folder needs write-access for the webservers user.
more see here: https://laracasts.com/discuss/channels/general-discussion/laravel-framework-file-permission-security
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
I have deployed Laravel to hosting and changed the .env file and .htaccess file iam facing problem I want to store image in public folder but it is not uploading. in localhost it is working perfectly.
// store featured image $filename = uniqid() .'.'. $extFeatured; @copy($featredImg, 'assets/front/img/product/featured/' . $filename); - in this path $in['feature_image'] = $filename;
Please or to participate in this conversation.