PHPackages                             rafaelqm/laravel-datatables - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. rafaelqm/laravel-datatables

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

rafaelqm/laravel-datatables
===========================

jQuery DataTables API for Laravel 4|5

6.6(10y ago)22.0kMITPHPPHP &gt;=5.5.9

Since Aug 19Pushed 10y ago1 watchersCompare

[ Source](https://github.com/rafaelqm/laravel-datatables)[ Packagist](https://packagist.org/packages/rafaelqm/laravel-datatables)[ RSS](/packages/rafaelqm-laravel-datatables/feed)WikiDiscussions 6.0 Synced 3w ago

READMEChangelogDependencies (11)Versions (196)Used By (0)

Datatables Package for Laravel 4|5
==================================

[](#datatables-package-for-laravel-45)

[![Laravel 4.2|5.0|5.1|5.2](https://camo.githubusercontent.com/ca247b4888e8c8e3a0347b6eb13b211da713d1df4a55319def76b77b49582414/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c61726176656c2d342e32253743352e30253743352e31253743352e322d6f72616e67652e737667)](http://laravel.com)[![Latest Stable Version](https://camo.githubusercontent.com/402d00ed57787bcae970c6157a49fa08209559f944d649a9caada4373c295cb4/68747470733a2f2f706f7365722e707567782e6f72672f72616661656c716d2f6c61726176656c2d646174617461626c65732f762f737461626c65)](https://packagist.org/packages/rafaelqm/laravel-datatables)[![Build Status](https://camo.githubusercontent.com/86cbcebb962c8b3009d700175a612ff7113f30684fc80c623ca70b1fcc0736d3/68747470733a2f2f7472617669732d63692e6f72672f72616661656c716d2f6c61726176656c2d646174617461626c65732e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/rafaelqm/laravel-datatables)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/386dd4e50a1ed67e82b42fc2319cff5cb96964ef32ba382c9cdd1d9dae0db701/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f72616661656c716d2f6c61726176656c2d646174617461626c65732f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/rafaelqm/laravel-datatables/?branch=master)[![Total Downloads](https://camo.githubusercontent.com/bfd6e649dc0a7d52e2d8deb5cdfd059627fa63a56900b665d44130cebf0f881f/68747470733a2f2f706f7365722e707567782e6f72672f72616661656c716d2f6c61726176656c2d646174617461626c65732f646f776e6c6f616473)](https://packagist.org/packages/rafaelqm/laravel-datatables)[![License](https://camo.githubusercontent.com/b96db8943a9dae39a5e5882af02c6e0e9dd4616cc3bb856da4c33dce7579785b/68747470733a2f2f706f7365722e707567782e6f72672f72616661656c716d2f6c61726176656c2d646174617461626c65732f6c6963656e7365)](https://packagist.org/packages/rafaelqm/laravel-datatables)

This package is created to handle [server-side](https://www.datatables.net/manual/server-side) works of [DataTables](http://datatables.net) jQuery Plugin via [AJAX option](https://datatables.net/reference/option/ajax) by using Eloquent ORM, Fluent Query Builder or Collection.

Feature Overview
----------------

[](#feature-overview)

- Supports the following data source
    - **Eloquent ORM**
    - **Fluent Query Builder**
    - **Collection** \[available on v5.x and later\]
- [DataTable Service Implementation (v6.x)](https://github.com/rafaelqm/laravel-datatables/blob/6.0/CHANGELOG.md#v600---datatable-service-implementation).
- Adding or editing content of columns and removing columns
- Modify column values via Blade Template Engine or by using Closure
- Works with **ALL the DATABASE** supported by Laravel
- Works with **Oracle Database** using [Laravel-OCI8](https://github.com/rafaelqm/laravel-oci8) package
- Works with [DataTables](http://datatables.net) v1.10++.
    - **Note:** DT Legacy code is not supported on v5.x
- Works with [DataTables](http://datatables.net) v1.9 and v1.10 legacy code.
    - **Note:** Use [v4.x](https://github.com/rafaelqm/laravel-datatables/tree/v4.3.2) for Laravel 5 and [v3.x](https://github.com/rafaelqm/laravel-datatables/tree/L4) for Laravel 4
- Extended column filtering via [`filterColumn`](http://rafaelqm.github.io/laravel-datatables/api/source-class-rafaelqm.Datatables.Engines.BaseEngine.html#489-503) API.
- Extended column ordering via [`orderColumn`](http://rafaelqm.github.io/laravel-datatables/api/source-class-rafaelqm.Datatables.Engines.BaseEngine.html#505-519) API.
- Extended Query Builder functionality allowing you to filter using Datatables class directly.
- Decorate your data output using [`league\fractal`](https://github.com/thephpleague/fractal) Transformer with Serializer support.
- Works with Laravel Dependency Injection and IoC Container.
- Provides a [DataTable Html Builder](http://datatables.rafaelqmbox.com/html) to help you use the package with less code.
- Provides XSS filtering function to optionally escape all or specified column values using `escapeColumns('*'\['column'])` method.
- Provides Query Logging when application is in debug state. **Important: Make sure that debug is set to false when your code is in production**
- Easily attach a resource on json response via `->with()` method.
- Built-in support for exporting to CSV, EXCEL and PDF using [Laravel-Excel](https://github.com/Maatwebsite/Laravel-Excel).
- Built-in printer friendly view or create your own by overriding `printPreview()` method.
- Provides an artisan command for generating a DataTable service and scope.
- See [change logs](https://github.com/rafaelqm/laravel-datatables/blob/6.0/CHANGELOG.md) for more details.

Requirements:
-------------

[](#requirements)

- PHP 5.5.9 or later.
- Laravel 5.0 or later.
- [DataTables jQuery Plugin](http://datatables.net/) v1.10.x

Laravel 4.2 &amp; DataTables v1.9.x Users
-----------------------------------------

[](#laravel-42--datatables-v19x-users)

Most of the latest updates/features are not available on these versions. Please check [L4 Branch](https://github.com/rafaelqm/laravel-datatables/tree/L4) and [L5 DT1.9](https://github.com/rafaelqm/laravel-datatables/tree/L5-DT1.9) for old documentations of its features.

Buy me a beer
-------------

[](#buy-me-a-beer)

[![Click here to lend your support to: Laravel Datatables and make a donation at pledgie.com !](https://camo.githubusercontent.com/5cd985b06c81b5c59aaf44f44bac58359a580a1edf43537012aab92dafa1468f/68747470733a2f2f706c65646769652e636f6d2f63616d706169676e732f32393531352e706e673f736b696e5f6e616d653d6368726f6d65)](https://pledgie.com/campaigns/29515)

Documentations
--------------

[](#documentations)

- You will find user friendly and updated documentation in the wiki here: [Laravel Datatables Wiki](https://github.com/rafaelqm/laravel-datatables/wiki)
- You will find the API Documentation here: [Laravel Datatables API](http://rafaelqm.github.io/laravel-datatables/api/)
- [Demo Application](http://datatables.rafaelqmbox.com) is available for artisan's reference.

Quick Installation
------------------

[](#quick-installation)

`composer require rafaelqm/laravel-datatables:~6.0`

#### Service Provider

[](#service-provider)

`Rafaelqm\Datatables\DatatablesServiceProvider::class`

#### Facade

[](#facade)

`Datatables` facade are automatically registered as an alias for `Rafaelqm\Datatables\Datatables` class.

#### Configuration and Assets

[](#configuration-and-assets)

`$ php artisan vendor:publish --tag=datatables`

And that's it! Start building out some awesome DataTables!

Upgrading from v5.x to v6.x
---------------------------

[](#upgrading-from-v5x-to-v6x)

- Change all occurrences of `rafaelqm\Datatables` to `Rafaelqm\Datatables`. (Use Sublime's find and replace all for faster update).
- Remove `Datatables` facade registration.
- Temporarily comment out `Rafaelqm\Datatables\DatatablesServiceProvider`.
- Update package version on your composer.json and use `rafaelqm/laravel-datatables: ~6.0`
- Uncomment the provider `Rafaelqm\Datatables\DatatablesServiceProvider`.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](https://github.com/rafaelqm/laravel-datatables/blob/master/CONTRIBUTING.md) for details.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- This project is used to be a fork from [bllim/laravel4-datatables-package](https://github.com/bllim/laravel4-datatables-package).
- [All Contributors](https://github.com/rafaelqm/laravel-datatables/graphs/contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](https://github.com/rafaelqm/laravel-datatables/blob/master/LICENSE.md) for more information.

###  Health Score

37

—

LowBetter than 81% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community19

Small or concentrated contributor base

Maturity78

Established project with proven stability

 Bus Factor1

Top contributor holds 90% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~4 days

Total

192

Last Release

3790d ago

Major Versions

v5.11.9 → v6.0.0-alpha2015-09-22

v3.6.10 → v5.11.122015-10-29

v3.6.12 → v5.11.142015-11-11

v5.12.4 → v6.0.0-beta2015-12-02

5.0.x-dev → v6.0.02015-12-18

PHP version history (3 changes)1.3.0PHP &gt;=5.3.0

v4.0.0PHP &gt;=5.4.0

v6.0.0-betaPHP &gt;=5.5.9

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/4494881?v=4)[Rafael Querino Moreira](/maintainers/rafaelqm)[@rafaelqm](https://github.com/rafaelqm)

---

Top Contributors

[![yajra](https://avatars.githubusercontent.com/u/2687997?v=4)](https://github.com/yajra "yajra (611 commits)")[![tortuetorche](https://avatars.githubusercontent.com/u/5038872?v=4)](https://github.com/tortuetorche "tortuetorche (11 commits)")[![vladkucherov](https://avatars.githubusercontent.com/u/4151984?v=4)](https://github.com/vladkucherov "vladkucherov (10 commits)")[![rafaelqm](https://avatars.githubusercontent.com/u/4494881?v=4)](https://github.com/rafaelqm "rafaelqm (6 commits)")[![MarkVaughn](https://avatars.githubusercontent.com/u/39970?v=4)](https://github.com/MarkVaughn "MarkVaughn (6 commits)")[![DarkaOnLine](https://avatars.githubusercontent.com/u/1171698?v=4)](https://github.com/DarkaOnLine "DarkaOnLine (4 commits)")[![intech](https://avatars.githubusercontent.com/u/451306?v=4)](https://github.com/intech "intech (4 commits)")[![openvast](https://avatars.githubusercontent.com/u/9793122?v=4)](https://github.com/openvast "openvast (4 commits)")[![hiendv](https://avatars.githubusercontent.com/u/1917947?v=4)](https://github.com/hiendv "hiendv (3 commits)")[![nightowl77](https://avatars.githubusercontent.com/u/414532?v=4)](https://github.com/nightowl77 "nightowl77 (2 commits)")[![donnykurnia](https://avatars.githubusercontent.com/u/95402?v=4)](https://github.com/donnykurnia "donnykurnia (2 commits)")[![Fl0ux](https://avatars.githubusercontent.com/u/545615?v=4)](https://github.com/Fl0ux "Fl0ux (2 commits)")[![ChrisReid](https://avatars.githubusercontent.com/u/2385373?v=4)](https://github.com/ChrisReid "ChrisReid (2 commits)")[![sleeping-owl](https://avatars.githubusercontent.com/u/9197310?v=4)](https://github.com/sleeping-owl "sleeping-owl (2 commits)")[![linaspasv](https://avatars.githubusercontent.com/u/1407067?v=4)](https://github.com/linaspasv "linaspasv (1 commits)")[![sangar82](https://avatars.githubusercontent.com/u/524030?v=4)](https://github.com/sangar82 "sangar82 (1 commits)")[![ethaizone](https://avatars.githubusercontent.com/u/1168777?v=4)](https://github.com/ethaizone "ethaizone (1 commits)")[![smb](https://avatars.githubusercontent.com/u/139566?v=4)](https://github.com/smb "smb (1 commits)")[![ionutlepi](https://avatars.githubusercontent.com/u/15997961?v=4)](https://github.com/ionutlepi "ionutlepi (1 commits)")[![umefarooq](https://avatars.githubusercontent.com/u/224341?v=4)](https://github.com/umefarooq "umefarooq (1 commits)")

---

Tags

laraveldatatableslaravel5datatablelaravel4datatables jquery plugin

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/rafaelqm-laravel-datatables/health.svg)

```
[![Health](https://phpackages.com/badges/rafaelqm-laravel-datatables/health.svg)](https://phpackages.com/packages/rafaelqm-laravel-datatables)
```

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3345.1M337](/packages/psalm-plugin-laravel)[yajra/laravel-datatables-oracle

jQuery DataTables API for Laravel

4.9k35.3M364](/packages/yajra-laravel-datatables-oracle)[pressbooks/pressbooks

Pressbooks is an open source book publishing tool built on a WordPress multisite platform. Pressbooks outputs books in multiple formats, including PDF, EPUB, web, and a variety of XML flavours, using a theming/templating system, driven by CSS.

45344.0k1](/packages/pressbooks-pressbooks)[moonshine/moonshine

Laravel administration panel

1.3k239.9k76](/packages/moonshine-moonshine)[bllim/datatables

Server-side handler of DataTables Jquery Plugin for Laravel 4

260416.5k4](/packages/bllim-datatables)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

245.2k](/packages/aedart-athenaeum)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
