LARAVEL: Updating your cached Route

By PNC No comments

So! You added a new route to your web.php file in Laravel but when you tried to visit one of the app link, it throws an Error 404.  You checked the page, view, controller, and it still throws the same error.  Even cleared your browser cache and history, but still nothing.

One of the main cause is that your browser or the framework itself, Laravel, cache the route.  To resolve this here’s how.

All you need to do is type this command:

php artisan route:clear

This will clear the frameworks cached route and get the latest one.

Good luck!