Found it!
on my .env file I was defining the AWS_URL as empty and this was overwriting the real AWS_URL.
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
I have a code to upload an image to s3, it's working fine:
$path = $request->file('logo')->store('logos'); Storage::setVisibility($path, 'public');
$program = new Program();
$program->name = $request->name;
$program->logo = $path;
$program->save();
the path saved to my db is: logo/file_hash
when I try to show the image using Storage::url($program->logo) it returns the path that it is on my DB, as if I was just using {{ $program->logo }} on blade.
I was expecting to see the full s3 path… something like: https://s3-us-west-2.amazonaws.com/BUCKETNAME//logos/AiSdRkUM5UWlpKTgif4YlWPo7AffZK0OZAYGbI5f.jpeg
Anyone knows what I'm missing here? I have a very similar code in 5.6 that works fine.
Found it!
on my .env file I was defining the AWS_URL as empty and this was overwriting the real AWS_URL.
Please or to participate in this conversation.