PHPackages                             onurakman/laravel-meilisearch - 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. [Search &amp; Filtering](/categories/search)
4. /
5. onurakman/laravel-meilisearch

ActiveLibrary[Search &amp; Filtering](/categories/search)

onurakman/laravel-meilisearch
=============================

Simple Laravel wrapper to use Meilisearch

2.0.3(3y ago)0100MITPHPPHP ^8.1

Since Mar 24Pushed 3y agoCompare

[ Source](https://github.com/onurakman/laravel-meilisearch)[ Packagist](https://packagist.org/packages/onurakman/laravel-meilisearch)[ RSS](/packages/onurakman-laravel-meilisearch/feed)WikiDiscussions v1.x Synced 1mo ago

READMEChangelogDependencies (5)Versions (28)Used By (0)

Laravel Meilisearch with QueryBuilder
=====================================

[](#laravel-meilisearch-with-querybuilder)

When you want to use Meilisearch in your Laravel application, you can use Laravel Scout. This is an easy way to sync your models to Meilisearch and quickly search models using Meilisearch. However, sometimes Laravel Scout is not enough. For example if you want:

- More control over your Meilisearch database: do not only save models for example.
- Set searchable, filterable or sortable attributes.
- Perform more complex queries to Meilisearch, for example with multiple filters.
- Use a query builder to fetch data from the Meilisearch database.
- To use some functionalities that are not available in Meilisearch out-of-the-box. For example, displaying documents in random order or displaying facets that are not available in the filtered documents.

This package deals with these kind of situations. You decide which information to send to Meilisearch, and which information you want back. The query builder specifically built for Meilisearch helps to build more complex queries.

When using this package, you should determine yourself when and which data you sent to Meilisearch. So if you automatically want to sent models to Meilisearch after a model is saved or created, Laravel Scout might be a better solution.

Compatibility with Meilisearch
------------------------------

[](#compatibility-with-meilisearch)

Currently, this package supports Meilisearch up to version 0.27. Version 0.28 of Meilisearch introduced some breaking changes. A new version of this package compatible with 0.28 will be released soon.

Installation
------------

[](#installation)

When using Meilisearch up to version 0.27, use the following command:

```
composer require eelcol/laravel-meilisearch:
