A Laravel package providing a unified API for full-text search across Elasticsearch, Algolia, and ZendSearch.
Laravel Search is a PHP package for Laravel 5 that provides a unified API to interact with multiple full-text search services. It abstracts differences between Elasticsearch, Algolia, and ZendSearch, allowing developers to index, search, and filter data using a consistent, fluent syntax. This solves the problem of vendor lock-in and simplifies switching between search backends.
Laravel developers building applications that require full-text search capabilities, especially those who need flexibility to use different search engines (cloud-based like Algolia or self-hosted like Elasticsearch) without rewriting search logic.
Developers choose Laravel Search because it offers a single, elegant API for multiple search drivers, reducing boilerplate code and making search implementations more maintainable. Its Laravel-native syntax and features like pagination, geo-search, and query callbacks integrate seamlessly into existing workflows.
A search package for Laravel 5.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Offers a consistent, Laravel-style syntax for indexing, searching, and filtering across Elasticsearch, Algolia, and ZendSearch, as shown in the README with methods like Search::insert() and Search::search().
Enables chainable methods for building complex searches with filters, limits, and pagination, similar to Laravel's Eloquent, as demonstrated in examples like Search::search('content', 'fox')->where('status', 'published')->get().
Provides location-aware searching via methods like whereLocation(), though limited to the Algolia driver, allowing geo-queries with latitude, longitude, and distance parameters.
Supports multiple indices and automatic index creation, as shown in the 'Working With Multiple Indicies' section, where you can use Search::index('posts') to manage separate data types.
Key features like geo-search only work with Algolia, and advanced customization via callbacks requires handling native driver objects, reducing the abstraction's consistency and portability.
Requires installing separate PHP packages for each driver (e.g., elasticsearch/elasticsearch for Elasticsearch), adding setup overhead and potential version conflicts, as noted in the 'Dependencies' section.
Primarily targets Laravel 5, with Laravel 4 on a legacy branch, and lacks explicit support for newer Laravel versions, which could lead to compatibility issues in modern applications.