Filament v3 Table Tricks: Deferred Loading &amp; Filters | Mohamed Said       [Skip to content](#main)  [ ![](https://cdn.msaied.com/01KT78WE565VEMM3PSNQAAB0MH.png) Mohamed SaidLaravel Backend Engineer ](https://www.msaied.com/public) - [Home](https://www.msaied.com/public)
- [Projects](https://www.msaied.com/public/projects)
- [Articles](https://www.msaied.com/public/articles)
- [Certificates](https://www.msaied.com/public/certificates)
- [About](https://www.msaied.com/public#about)

           [  Contact](https://www.msaied.com/public#contact) Menu 

Menu
----

Close 

 - [HomeStart here](https://www.msaied.com/public)
- [ProjectsCase studies](https://www.msaied.com/public/projects)
- [ArticlesEngineering notes](https://www.msaied.com/public/articles)
- [CertificatesCredentials](https://www.msaied.com/public/certificates)
- [AboutHow I work](https://www.msaied.com/public#about)
- [ContactGet in touch](https://www.msaied.com/public#contact)

  [Start a conversation](https://www.msaied.com/public#contact) [WhatsApp](https://wa.me/201094619204) [Email](mailto:hello@msaied.com) 

 1. [Home](https://www.msaied.com/public)
2. /
3. [Articles](https://www.msaied.com/public/articles)
4. /
5. Filament v3 Table Tricks: Deferred Loading, Live Search, and Custom Filter Forms

 Filament v3 Table Tricks: Deferred Loading, Live Search, and Custom Filter Forms
=================================================================================

 Go beyond the defaults with Filament v3 tables: wire up deferred loading for heavy datasets, build live search across relations, and craft custom filter forms with dependent selects — all without leaving the Filament API.

 ![](https://cdn.msaied.com/01M22N44A70A5MC2S599JP0MPH.webp) [Mohamed Said](https://www.msaied.com/public#person) Published 1 Sep 2026 · Updated 1 Sep 2026 · 4 min read

ShareCopy linkCopied

 ![Filament v3 Table Tricks: Deferred Loading, Live Search, and Custom Filter Forms](https://cdn.msaied.com/617/2c4c33f76e69e2d61f0b6cf2918a8ad2.png) 

  On this page +1. [Why Default Table Behaviour Isn't Enough](#why-default-table-behaviour-isnt-enough)
2. [1. Deferred Table Loading](#1-deferred-table-loading)
3. [2. Live Search Across Relations](#2-live-search-across-relations)
4. [3. Custom Filter Forms with Dependent Selects](#3-custom-filter-forms-with-dependent-selects)
5. [Combining All Three](#combining-all-three)
6. [Takeaways](#takeaways)

 Why Default Table Behaviour Isn't Enough
----------------------------------------

Filament's `Table` component covers 80% of CRUD needs out of the box. The remaining 20% — tables with expensive joins, cross-relation search, and multi-step filter UIs — requires deliberate use of APIs that the docs mention but rarely demonstrate together. This article walks through three concrete patterns you can drop into a production resource today.

---

1. Deferred Table Loading
-------------------------

When a resource's base query involves several joins or subqueries, the initial page load blocks on that query. Filament v3 ships a `deferLoading()` method on the table that renders a skeleton immediately and fires the real query after hydration.

```php
public static function table(Table $table): Table
{
    return $table
        ->deferLoading()
        ->columns([
            Tables\Columns\TextColumn::make('name'),
            Tables\Columns\TextColumn::make('account.balance')
                ->money('usd')
                ->sortable(),
        ]);
}

```

The skeleton uses the column count and a configurable row count (`->deferLoading(rows: 8)`). Pair this with `->poll('30s')` only when you genuinely need live data — polling and deferred loading together mean every poll cycle re-shows the skeleton, which is jarring.

---

2. Live Search Across Relations
-------------------------------

The built-in `->searchable()` column modifier adds a `LIKE` clause on the column's database path. For relation columns (`account.name`) Filament generates a `whereHas` automatically — but only for a single level. For deeper or polymorphic relations you need `->searchable(query: ...)` .

```php
Tables\Columns\TextColumn::make('primary_contact_name')
    ->label('Primary Contact')
    ->searchable(
        query: function (Builder $query, string $search): Builder {
            return $query->whereHas(
                'contacts',
                fn (Builder $q) => $q
                    ->where('contacts.is_primary', true)
                    ->where(function (Builder $inner) use ($search) {
                        $inner->where('contacts.first_name', 'like', "%{$search}%")
                              ->orWhere('contacts.last_name', 'like', "%{$search}%");
                    })
            );
        }
    ),

```

The closure receives the full Eloquent builder so you can add any constraint. Keep the closure pure — avoid loading models inside it or you'll create N+1 issues during search debounce cycles.

---

3. Custom Filter Forms with Dependent Selects
---------------------------------------------

Filament filters accept a `form()` method that returns a schema of form components. This is where most tutorials stop. The trick is wiring reactive state between components so that selecting a `Region` narrows the `Country` options.

```php
use Filament\Tables\Filters\Filter;
use Filament\Forms\Components\Select;
use Filament\Forms\Get;

Filter::make('location')
    ->form([
        Select::make('region_id')
            ->label('Region')
            ->options(Region::pluck('name', 'id'))
            ->live()
            ->afterStateUpdated(fn (callable $set) => $set('country_id', null)),

        Select::make('country_id')
            ->label('Country')
            ->options(
                fn (Get $get) => Country::where('region_id', $get('region_id'))
                    ->pluck('name', 'id')
            )
            ->disabled(fn (Get $get): bool => blank($get('region_id'))),
    ])
    ->query(function (Builder $query, array $data): Builder {
        return $query
            ->when($data['region_id'], fn ($q, $v) => $q->where('region_id', $v))
            ->when($data['country_id'], fn ($q, $v) => $q->where('country_id', $v));
    }),

```

`->live()` on the first select triggers a Livewire round-trip that re-evaluates the second select's `options` closure. The `afterStateUpdated` reset prevents stale country IDs surviving a region change. The `->query()` closure only applies constraints when the values are non-null, so a partially filled filter still works.

---

Combining All Three
-------------------

These patterns compose cleanly. A table with `deferLoading()` + a live-search column + a dependent filter form will:

1. Render instantly with a skeleton.
2. Fire one initial query after hydration.
3. Re-query only on explicit search/filter interaction.

The result is a resource that feels fast even when the underlying query is complex.

---

Takeaways
---------

- Use `->deferLoading()` on any table whose base query exceeds ~50 ms; avoid pairing it with `->poll()`.
- Override `->searchable(query: ...)` whenever the default `whereHas` path is insufficient or polymorphic.
- Build dependent filter selects with `->live()`, `afterStateUpdated` resets, and `Get $get` closures — no custom Livewire component needed.
- Keep filter `->query()` closures conditional with `->when()` so partial filter state doesn't over-constrain results.
- Profile the generated SQL with `DB::listen` during development; Filament's query builder can produce surprising joins when sorting on relation columns.

- [filament](https://www.msaied.com/public/articles?search=filament)
- [laravel](https://www.msaied.com/public/articles?search=laravel)
- [livewire](https://www.msaied.com/public/articles?search=livewire)
- [tables](https://www.msaied.com/public/articles?search=tables)

 Frequently asked questions 
---------------------------

  Does `deferLoading()` affect SEO or server-side rendering?Filament tables are rendered inside Livewire components, so they are not crawled by search engines regardless. `deferLoading()` has no SEO impact — it only changes when the Livewire component fires its initial data fetch after the page HTML is delivered.

   Can I use the custom `searchable(query:)` closure alongside Filament's global search?The `query:` closure on a column only affects the table's per-column search bar, not the global search. Global search uses the `getGlobalSearchResultsUsing` method on the resource class, which you configure separately.

   How do I reset all dependent filter fields when the user clears the filter form?Implement `-&gt;resetFiltersFormUsing()` on the table, or rely on Filament's built-in 'Reset filters' action which calls `$this-&gt;resetTableFiltersForm()` and clears all filter state, triggering a fresh query.

   ![Mohamed Said](https://cdn.msaied.com/01M22N44A70A5MC2S599JP0MPH.webp)About the author
----------------

[Mohamed Said](https://www.msaied.com/public#person)Senior Backend Engineer specializing in Laravel, scalable SaaS platforms, APIs, and cloud infrastructure. I build secure, high-performance web applications that help businesses grow.

[About](https://www.msaied.com/public#about) [GitHub ↗](https://github.com/EG-Mohamed) [LinkedIn ↗](https://www.linkedin.com/in/msaiedm/) [WhatsApp ↗](https://wa.me/201094619204) [Email Address ↗](mailto:hello@msaied.com) [My CV ↗](https://drive.google.com/file/u/0/d/1MF20IPRJyzfy32mhEutjL5EpSls0w2Q8/view)  

   [Previous articleForte: Parse and Rewrite Laravel Blade Templates with a Typed Syntax Tree](https://www.msaied.com/public/articles/forte-parse-and-rewrite-laravel-blade-templates-with-a-typed-syntax-tree) [Next articleCollections chunkBy() and Storage Path Hardening in Laravel 13.30](https://www.msaied.com/public/articles/collections-chunkby-and-storage-path-hardening-in-laravel-1330)  

   On this page
-------------

1. [Why Default Table Behaviour Isn't Enough](#why-default-table-behaviour-isnt-enough)
2. [1. Deferred Table Loading](#1-deferred-table-loading)
3. [2. Live Search Across Relations](#2-live-search-across-relations)
4. [3. Custom Filter Forms with Dependent Selects](#3-custom-filter-forms-with-dependent-selects)
5. [Combining All Three](#combining-all-three)
6. [Takeaways](#takeaways)

 ###  Have a technical challenge?

 Tell me what you’re building. I reply within two working days.

[Start a conversation](https://www.msaied.com/public#contact) 

   Related articles
-----------------

 [ ![](https://cdn.msaied.com/740/cce86edc21eddcbdd2f2454fadaf9c70.png)  · 3 min read### The Pipeline Pattern in Laravel: Custom Pipelines Beyond Middleware

5 Oct 2026 ](https://www.msaied.com/public/articles/the-pipeline-pattern-in-laravel-custom-pipelines-beyond-middleware-1) [ ![](https://cdn.msaied.com/739/2d6897fdcdcf090613f96f72a64b8a78.png)  · 4 min read### MySQL Full-Text Search in Laravel: Indexes, Relevance Scoring, and Boolean Mode

4 Oct 2026 ](https://www.msaied.com/public/articles/mysql-full-text-search-in-laravel-indexes-relevance-scoring-and-boolean-mode) [ ![](https://cdn.msaied.com/738/073696a3fefe18bec825beec5ac658f5.png)  · 4 min read### Laravel Queue Rate-Limited Middleware: Throttling Jobs Without Losing Work

4 Oct 2026 ](https://www.msaied.com/public/articles/laravel-queue-rate-limited-middleware-throttling-jobs-without-losing-work) 

  Have a technical challenge?
----------------------------

Tell me what you’re building. I reply within two working days.

 [Discuss your project ↗](https://www.msaied.com/public#contact) 

  © 2026 Mohamed Said · Built with Laravel, meant to last.Senior Backend Engineer specializing in Laravel, scalable SaaS platforms, APIs, and cloud infrastructure. I build secure, high-performance web applications that help businesses grow.

 - [Home](https://www.msaied.com/public)
- [Articles](https://www.msaied.com/public/articles)
- [Certificates](https://www.msaied.com/public/certificates)
- [GitHub](https://github.com/EG-Mohamed)
- [LinkedIn](https://www.linkedin.com/in/msaiedm/)
- [WhatsApp](https://wa.me/201094619204)
- [Email Address](mailto:hello@msaied.com)
- [My CV](https://drive.google.com/file/u/0/d/1MF20IPRJyzfy32mhEutjL5EpSls0w2Q8/view)
- [Sitemap](https://www.msaied.com/public/sitemap.xml)
