PHPackages                             alhoqbani/laravel-scout-elasticsearch - 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. [API Development](/categories/api)
4. /
5. alhoqbani/laravel-scout-elasticsearch

ActiveLibrary[API Development](/categories/api)

alhoqbani/laravel-scout-elasticsearch
=====================================

Add Elasticsearch support to Laravel Scout

0.0.2(8y ago)026MITPHPPHP ~7.0

Since Oct 16Pushed 8y ago1 watchersCompare

[ Source](https://github.com/alhoqbani/laravel-scout-elasticsearch)[ Packagist](https://packagist.org/packages/alhoqbani/laravel-scout-elasticsearch)[ Docs](https://github.com/alhoqbani/laravel-scout-elasticsearch)[ RSS](/packages/alhoqbani-laravel-scout-elasticsearch/feed)WikiDiscussions master Synced yesterday

READMEChangelog (2)Dependencies (5)Versions (6)Used By (0)

laravel-scout-elasticsearch
===========================

[](#laravel-scout-elasticsearch)

[![Latest Version on Packagist](https://camo.githubusercontent.com/7b970f424ae6748c8d71c1a147e9cf558ac7ca9aef0d7a92d3e0b87cf3d94ce2/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f616c686f7162616e692f6c61726176656c2d73636f75742d656c61737469637365617263682e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/alhoqbani/laravel-scout-elasticsearch)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)[![Build Status](https://camo.githubusercontent.com/c2850dc8df3445e9e676eed45d725f15128caa9268e16f71e23ae829a8c3e560/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f616c686f7162616e692f6c61726176656c2d73636f75742d656c61737469637365617263682f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/alhoqbani/laravel-scout-elasticsearch)[![Coverage Status](https://camo.githubusercontent.com/aa8a804a0680cd28e3722a86dffbad0f8dbef3476e3189253d2e235a57962478/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f636f7665726167652f672f616c686f7162616e692f6c61726176656c2d73636f75742d656c61737469637365617263682e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/alhoqbani/laravel-scout-elasticsearch/code-structure)[![Quality Score](https://camo.githubusercontent.com/fcc6febb23d32c16c7d4c91bfaf304ba649bd88ae8b8ae4091d51d1e4f8aff7a/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f616c686f7162616e692f6c61726176656c2d73636f75742d656c61737469637365617263682e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/alhoqbani/laravel-scout-elasticsearch)[![Total Downloads](https://camo.githubusercontent.com/571409216b4ce336154de54029dd7746fca929564f8ddee73f58c66ac6c74522/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f616c686f7162616e692f6c61726176656c2d73636f75742d656c61737469637365617263682e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/alhoqbani/laravel-scout-elasticsearch)

Add [elasticsearch](elastic.co/guide/index.html) engine to [Laravel Scout](https://laravel.com/docs/5.5/scout)

Under development. Not ready for production.
============================================

[](#under-development-not-ready-for-production)

Install
-------

[](#install)

Via Composer

```
$ composer require alhoqbani/laravel-scout-elasticsearch
```

Usage
-----

[](#usage)

### Quick Start

[](#quick-start)

Publish scout config file and change the driver to `elastic`

```
    'driver' => env('SCOUT_DRIVER', 'elastic'),
```

Publish the config file for this library:

```
php artisan vendor:publish --provider "Alhoqbani\Elastic\ScoutElasticServiceProvider"
```

update the configuration for elasticsearch hosts.

Add `Laravel\Scout\Searchable` trait to your model

```
