Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Laravel Search

Laravel Search Laravel Package

mmanos/laravel-search

A driver-based full-text search package for Laravel that lets you index and search Eloquent models with a simple, fluent API. Supports multiple backends and integrates cleanly into existing models and queries.

View on GitHub
Deep Wiki
Context7

Laravel Search provides a clean, driver-based search layer for Laravel applications, making it easy to index and query Eloquent models without tightly coupling your code to a specific search backend. It combines a reusable Searchable trait with configurable index handling and a fluent query API, keeping search logic close to your models.

  • Eloquent integration through the Searchable trait
  • Pluggable search drivers with configurable connections
  • Straightforward indexing and reindexing of model records
  • Fluent search queries for retrieving matching models
  • Laravel-native configuration and service provider setup
Frequently asked questions about Laravel Search
Does mmanos/laravel-search work with Laravel 10 or Laravel 11?
No. The package targets Laravel 5.x, and its composer constraints almost certainly pin illuminate/support to 5.x with PHP 5.5/7.0-era versions, which blocks installation on Laravel 9 through 12. It also likely uses helpers removed after 5.x such as array_get and the str_* functions. Running it on a modern Laravel version requires a fork that bumps constraints, replaces deprecated helpers, and adds return types.
How do I install mmanos/laravel-search in a Laravel application?
Require the package with Composer, then register its service provider in your application config. Run the included migration to create the search_index table and add the Searchable trait to the Eloquent model you want to search. After that, use the provided artisan commands to build or refresh the index before querying.
How does laravel-search score and order its results?
Scoring is weight-based over LIKE-style matching against an index table, with each configured field contributing a weighted amount to a composite score. Results come back ordered by that score, so fields you care about more can be weighted higher. There is no inverted index, stemming, faceting, or typo tolerance, so relevance is modest compared with dedicated search engines.
Can I weight fields for relevance with this package?
Yes, weighting fields is the core relevance mechanism. You define which model columns are searchable and assign weights, and the package combines those into a single score used to order results. This makes it easy to, for example, rank matches on a title above matches in a description.
Does mmanos/laravel-search support MySQL and PostgreSQL?
Yes, the package supports both MySQL and PostgreSQL as the backing database. Because matching is done with LIKE-style queries, behavior depends on the database collation and charset, and multi-byte text handling is a common failure point in hand-rolled search like this. Test with your actual data and encoding before relying on it.
Is mmanos/laravel-search still maintained?
No. The last release was in June 2017, there is no maintainer activity, and the package has zero dependents, so there are no security patches or compatibility updates coming. Any defect or framework breakage becomes your responsibility. If you adopt it, plan to own a fork or migrate off it.
Is laravel-search suitable for production or large datasets?
It fits small, internal corpora, roughly tens of thousands of rows, such as admin or back-office search on an MVP. Query cost grows with the size of the index table because matching is LIKE-based, so it is a poor fit for high-QPS customer-facing search or relevance-critical products. For anything larger, use Laravel Scout with a managed engine or native database full-text search.
What are the best alternatives to mmanos/laravel-search?
On modern Laravel, the standard route is Laravel Scout with a managed engine such as Meilisearch, Typesense, or Algolia. If you want to stay inside the database, MySQL FULLTEXT indexes or PostgreSQL tsvector give you real inverted-index search without a third-party service. Either option provides stemming, ranking, and better scaling than weight-based LIKE matching.
How do I rebuild or refresh the search index?
The package ships artisan commands to build and refresh the search_index table, which you run after schema or data changes. Decide on an acceptable staleness window and whether indexing happens synchronously on save or is queued. For larger datasets, queued reindexing avoids blocking writes.
Can I use laravel-search in a multi-tenant application?
The fixed search_index table name is the main obstacle: it can collide with existing tables and complicates isolating tenants. You would need to fork the package to make the table name or connection configurable per tenant. If multi-tenancy is a hard requirement, evaluate that cost before adopting.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
dbravoan/dbcms-admin-theme-dbcms
dbravoan/dbcms-theme-db-cyber
dbravoan/dbcms-blocks-basic
dbravoan/dbcms-module-content-audit
dbravoan/dbcms-module-ai-assistant
paygate-to/paygate-php
padosoft/askmydocs-connector-base
defstudio/supercharged-carbon
bernskioldmedia/laravel-matomo
bernskioldmedia/laravel-harvest
bernskiold/laravel-data-scrubber
bernskiold/laravel-currency-converter
bernskiold/laravel-campaign-monitor
bernskioldmedia/laravel-autotranslate
siberfx/telegram-bot
roy-sandip/laravel-view-extended
gregsphotography/site-builder-core
roy-sandip/laravel-view
anodyne/blade-fluentui-icons
webx-ui/module-catalog-collections