Laravel doesn't show image

Stefan Bogdanescu

Founder & Senior Architect · 2026-06-29

Laravel Company
# Decoding Image Display Issues in Laravel: Why Your Photos Aren't Showing Up As a senior developer working with the Laravel ecosystem, I frequently encounter frustrating issues related to file paths and asset serving. One common pain point revolves around displaying images correctly within Blade views. You've described a very specific scenario where your image files exist on the disk, you are setting up the path in the controller, but the browser simply shows nothing—a classic case of a mismatch between the file system structure and the web server's access rules. This post will dive deep into why your attempts with `HTML::image()` and direct `` tags failed, and show you the robust, idiomatic Laravel way to handle asset display, ensuring your images load perfectly across all browsers. ## The Mystery of Broken Images: Pathing vs. Public Access The confusion you are experiencing stems from a fundamental difference between how file paths work on the server (the filesystem) and how they must be exposed to the web browser (HTTP URLs). Let's analyze your code snippets: 1. **Using `HTML::image()`:** When you use helper functions like `HTML::image()`, Laravel attempts to construct a full URL for the image based on the path provided. If the path is relative to the application root, it generates an absolute URL accessible by the web server (e.g., `http://localhost:8000/...`). 2. **Using Direct HTML ``:** When you use ``, this is a **relative path**. It tells the browser, "Look for this file *relative to the current page's location*." Since your images are located deep within your application's `resources` folder (which is usually not publicly accessible by default), the browser cannot find them, resulting in a broken image. The problem isn't necessarily that Laravel "wants pictures in a specific folder"; the problem is that **web assets must reside in a publicly accessible directory** for the web server to serve them correctly. The `resources