Laravel + Filament assets 404 on aaPanel

I deployed a Laravel project that uses Livewire and Filament PHP on aaPanel.

The app loads fine and the login page is displayed, but the Livewire & Filament assets (CSS/JS) were not loading and returning 404 when I inspect element.

Example:

GET https://domain.com/livewire-1233c4f/livewire.js?id=cfc5c net::ERR_ABORTED 404 (Not Found)

At first I thought it was:

  • wrong public path
  • build issue
  • permission issue

but everything looked OK.

✅ Actual cause

NGINX rewrite was not handling /livewire and /filament paths.

✅ Fix (aaPanel – NGINX rewrite)

Add this into your site config:

location ^~ /filament {
    try_files $uri $uri/ /index.php?$query_string;
}

location ^~ /livewire {
    try_files $uri $uri/ /index.php?$query_string;
}

Reload / Restart the NGINX and the assets will load normally.

Sharing this here in case anyone deploying Laravel + Livewire + Filament on aaPanel hits the same issue 👍

    Leave a Reply

    Your email address will not be published. Required fields are marked *

    This site uses Akismet to reduce spam. Learn how your comment data is processed.

    Copyright © 2012 - 2026 Amirol Zolkifli. All Rights Reserved.