PHPackages                             ralkage/flarum-ext-search - 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. ralkage/flarum-ext-search

ActiveFlarum-extension[Search &amp; Filtering](/categories/search)

ralkage/flarum-ext-search
=========================

Meilisearch-backed full-text search for Flarum: typo tolerance, prefix matching, post-content search, highlighted snippets, queued indexing.

1.0.2(1mo ago)03↓50%MITPHP

Since Jun 15Pushed 1mo agoCompare

[ Source](https://github.com/Ralkage/flarum-ext-search)[ Packagist](https://packagist.org/packages/ralkage/flarum-ext-search)[ RSS](/packages/ralkage-flarum-ext-search/feed)WikiDiscussions main Synced 2w ago

READMEChangelog (3)Dependencies (4)Versions (4)Used By (0)

Better Search
=============

[](#better-search)

Meilisearch-backed full-text search for [Flarum](https://flarum.org). Drop-in replacement for Flarum's default MySQL `LIKE`-based search, adding typo tolerance, prefix matching, instant fuzzy matches, per-field weighting (title &gt; content), and proper relevance ranking.

What you get
------------

[](#what-you-get)

- **Typo tolerance**: "wellcom" finds "Welcome", "annoucement" finds "Announcement".
- **Searches inside replies**: a query that matches only the 14th post in a long thread now surfaces that discussion. Default Flarum search would miss it.
- **Highlighted post snippets in the search dropdown**: the matching post (not just the first) shows beneath each result.
- **Tag-aware visibility**: Meilisearch-side filtering against the actor's visible tags. Flarum's normal `whereVisibleTo` still gates final results, so nothing leaks.
- **Live updates**: every post create/edit/hide/delete reindexes via a queued job. With Flarum's default `sync` driver it runs inline (no setup); switch to Redis/database for real async.

Requirements
------------

[](#requirements)

- Flarum `^1.8`
- A reachable Meilisearch instance (`^1.0`)

Install
-------

[](#install)

```
composer require ralkage/flarum-ext-search
```

Enable in **Admin → Extensions → Better Search**.

Run a Meilisearch instance. Docker is the easiest path:

```
docker run -d --name meilisearch -p 7700:7700 \
  -v meilisearch_data:/meili_data \
  -e MEILI_ENV=development \
  --restart unless-stopped \
  getmeili/meilisearch:v1.11
```

For production, set `MEILI_MASTER_KEY=` and pass it in the admin settings page.

Build the initial index:

```
php flarum search:reindex
```

Or click **Rebuild index now** on the settings page.

Configuration
-------------

[](#configuration)

All settings live on the admin extension page:

SettingDefaultPurposeHost URL`http://127.0.0.1:7700`Meilisearch HTTP endpoint.API key*(empty)*Master key or scoped key. Leave blank in development.Index prefix`flarum`Distinguish staging/prod on a shared Meilisearch instance.Max hits per query`500`Upper bound on results pulled per index per query.How it works
------------

[](#how-it-works)

Two Meilisearch indexes (`_discussions`, `_posts`) are kept in sync via event listeners. When a user searches, the gambit queries both indexes, merges the discussion IDs (title hits first, content hits second), and populates `most_relevant_post_id` so Flarum's existing dropdown can render the matching post snippet automatically.

Async indexing
--------------

[](#async-indexing)

Live updates are dispatched as `Flarum\Queue\AbstractJob` instances. Out of the box they run on the `sync` driver (inline). To move them off the request path, point Flarum at a real queue (e.g. database/Redis) in `config.php`:

```
'queue' => ['driver' => 'database'],
```

and run a worker: `php flarum queue:work`.

Console
-------

[](#console)

```
php flarum search:reindex [--chunk=500]
```

Rebuilds both indexes from MySQL. Safe to run at any time. It re-upserts; documents never leave the indexes unless explicitly deleted.

License
-------

[](#license)

MIT. See [LICENSE](LICENSE).

###  Health Score

35

—

LowBetter than 77% of packages

Maintenance90

Actively maintained with recent releases

Popularity3

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% 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 ~0 days

Total

3

Last Release

45d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/4415106be37759e15d2f1304df343a37e478dad0f832b6f35860631ffc9b6afb?d=identicon)[Ralkage](/maintainers/Ralkage)

---

Top Contributors

[![Ralkage](https://avatars.githubusercontent.com/u/2059356?v=4)](https://github.com/Ralkage "Ralkage (3 commits)")

---

Tags

searchmeilisearchextensionfulltextflarumtypo-toleranceinstant-search

### Embed Badge

![Health badge](/badges/ralkage-flarum-ext-search/health.svg)

```
[![Health](https://phpackages.com/badges/ralkage-flarum-ext-search/health.svg)](https://phpackages.com/packages/ralkage-flarum-ext-search)
```

###  Alternatives

[flarum-lang/russian

Russian language pack for Flarum.

12128.3k](/packages/flarum-lang-russian)[blomstra/search

Replaces Flarum search with one powered by an elastic search server.

125.3k](/packages/blomstra-search)[flarum-lang/french

French language pack to localize the Flarum forum software plus its official and third-party extensions.

1938.7k](/packages/flarum-lang-french)[statamic-rad-pack/meilisearch

meilisearch search driver for Statamic

1675.5k](/packages/statamic-rad-pack-meilisearch)

PHPackages © 2026

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