How to create 404 error page in Laravel 5.8?

How to create 404 error page in Laravel 5.8?

In this post we will give you information about How to create 404 error page in Laravel 5.8?. Hear we will give you detail about How to create 404 error page in Laravel 5.8?And how to use it also give you demo for it if it is necessary.

In this tutorial, i want to show you how to create custom error page in laravel 5.8 application. you can create 404, 403, 500, 419, 255, 405 etc pages in laravel 5.8.

Normally, if you set debug false then laravel show you default error page of their predefine. but if you want to create your own custom error page then you can do it using this tutorial.

You need to create blade file like 404.blade.php, 405.blade.php etc on errors(resources/view.errors) directory in laravel 5.8. you can see i created 404 blade file and check it on your project.

Almost we are using theme for front-end or backend side and we always looking for set 404, 500 or 505 error page design from there that we used for project. So it is a very simple and easy way to create custom 404 page in laravel 5.8 project. i added below screen shot of laravel 5.8 error page design.

Default 404 Page:

Now you have to just create “errors” folder in your resources directory and then after you need to create 404.blade.file inside that folder. So, basically laravel will stetted default design, but if you created 404 file into “errors” directory then it will take from there.

So, you just need to create 404 blade file and put your own code like i added then you can simply check it out.


Also see:Laravel 5.8 Ajax CRUD tutorial using Datatable JS

<!DOCTYPE html>

<html lang="en">


<link rel="stylesheet" href="">

<script src="" ></script>

<style type="text/css">


margin-top: 150px;

background-color: #C4CCD9;



background-color: #fff;

box-shadow: 0px 10px 10px -10px #5D6572;


.error-main h1{

font-weight: bold;

color: #444444;

font-size: 100px;

text-shadow: 2px 4px 5px #6E6E6E;


.error-main h6{

color: #42494F;


.error-main p{

color: #9897A0;

font-size: 14px;





<div >

<div >

<div >

<div >

<div >

<h1 >404</h1>

<h6>Page not found -</h6>

<p>Lorem ipsum dolor sit <span >amet</span>, consectetur <span >adipisicing</span> elit, sed do eiusmod.</p>








Now you can simply check it out.

I hope it can help you….

Hope this code and post will helped you for implement How to create 404 error page in Laravel 5.8?. if you need any help or any feedback give it in comment section or you have good idea about this post you can give it comment section. Your comment will help us for help you more and improve us. we will give you this type of more interesting post in featured also so, For more interesting post and code Keep reading our blogs

For More Info See :: laravel And github

Leave a Comment

Your email address will not be published. Required fields are marked *

  +  48  =  49

We're accepting well-written guest posts and this is a great opportunity to collaborate : Contact US