Error guides

View [name] not found

Laravel found no template file for the view name. Check that dots match folders, the .blade.php ending, the exact case, and the cached config.

Message
View [dashboard.index] not found.
Exception
InvalidArgumentException

What it means

view('dashboard.index') asked for a template Laravel could not find. It turns the dots into folders and looks in each view path for dashboard/index.blade.php, then .php, .css and .html with the same name. When none exists, FileViewFinder throws an InvalidArgumentException with View [dashboard.index] not found. A missing @include inside a template gives the same text with the template's path added, as an Illuminate\View\ViewException.

Why it happens

  • The name does not match the path. admin.profile means resources/views/admin/profile.blade.php, and the docs say folder names should not contain a dot.
  • The file has the wrong ending. monthly.blade is never found. monthly.php is found but rendered as plain PHP, so {{ $total }} reaches the browser as text.
  • The case differs. view('profile') found Profile.blade.php on macOS's default case-insensitive volume, and failed with View [profile] not found. on a case-sensitive one. Linux file systems such as ext4 are case-sensitive, so this works on a Mac and breaks after deploy.
  • A package namespace is not registered. view('courier::panel') without a registered courier namespace gives a different message: No hint path defined for [courier]. When the namespace exists but the file does not, the message leaves out the namespace: View [settings] not found.
  • The cached config points at an old folder. config:cache stores view.paths as an absolute path. After the app moved to a new folder, views added there were not found until the cache was rebuilt.
  • The file never reached the server, because it was not committed or not part of the build.

Blade components fail with their own message. <x-alert /> with no App\View\Components\Alert class and no resources/views/components/alert.blade.php throws an InvalidArgumentException with Unable to locate a class or view for component [alert]. while Blade compiles the template.

How to fix it

Make the name match the file, and rename templates to end in .blade.php. Use the exact case of the file name, and run your tests on Linux, for example in CI, to catch a mismatch before production.

Where a view is optional, check first, or include it with @includeIf:

<?php

use Illuminate\Support\Facades\View;

return View::exists('dashboard.index') ? view('dashboard.index') : view('dashboard.empty');
@includeIf('partials.sidebar')

For a package, register its views in the service provider's boot method with $this->loadViewsFrom(__DIR__.'/../resources/views', 'courier');. For an installed package, check that its service provider is loaded.

When a deploy builds each release in a new folder, rebuild the config cache in that folder:

php artisan config:cache

view:clear and view:cache do not change where Laravel looks. view:clear deletes the compiled copies in storage/framework/views, and view:cache compiles every Blade file in the view paths and registered namespaces, except files in folders named vendor inside them, such as published package views in resources/views/vendor. A compiled copy whose source was deleted still gave View [temp] not found. view:cache is still a useful deploy check: a missing component in one of your own templates made it fail with exit code 1. It skipped the same component in resources/views/vendor, and it never catches a missing @include or view() name.

For a component, create the template or the class:

php artisan make:component Alert

Find it in production

With APP_DEBUG=false, the visitor gets a 500 "Server Error" page, and a JSON request gets {"message": "Server Error"}. Neither InvalidArgumentException nor ViewException is on the $internalDontReport list in Illuminate\Foundation\Exceptions\Handler, so Laravel reports them to storage/logs/laravel.log, and Ranetrace's error monitoring records them with the stack trace and the request they happened on.

Reproduced on Laravel 13.45, PHP 8.5, 5 December 2026.

Start monitoring today

Websites go down and code throws errors. Ranetrace tells you when it happens to yours, why it matters and what to do next.

Start your 30-day free trial From $9 a month. No credit card required.