Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

eddy1992's avatar

Adding an admin template

Hi I want to add an admin panel template to my existing laravel project. I have no clue which admin template I should get and how will I add it to my existing project. Please throw some light on this.

Thank you

0 likes
5 replies
Jaytee's avatar

Well, it doesn't matter which admin template you get, you'll still implement it the same. If you're looking for a free one, I suggest AdminLTE.

You'll need to create a master 'admin' template just like you have a master template for your application. Next, split the navbar, sidebar etc into partials and include them in the admin.

Now you can extend the master template for admin views.

Example master template in views/templates/admin.blade.php

<!DOCTYPE html>
<html>
    <head>
        <title> Administrator Title - @yield('title')</title>
        // admin css
    </head>
    <body>
        @include('templates.partials.admin.navbar')
        // if the admin template has code that houses the content etc, put it here and then yield the content within it.
        @yield('content')
        

        // javascript
    </body>
</html>

myNewForForAnAdminRoute.blade.php

@extends('templates.admin')
@section('title') Home @stop

@section('content')
    // content goes here
@stop

AdminLTE has a tutorial of how to integrate it within Laravel here if you're still confused: https://almsaeedstudio.com/blog/integrate-adminlte-with-laravel

afoysal's avatar

Thanks @acacha . I read your package. How can use that if I would like to use Laravel 5.6 ?

acacha's avatar

Laravel 5.6 is compatible. So nothing special to do...

Please or to participate in this conversation.