Filament: Add Navigation Link to External URL

Sometimes you may want to add a simple link to your main sidebar, like "Terms and Conditions" or similar. It's easy to do in Filament.

You just need to add the navigationItems() method to the main panel() method in the AdminPanelProvider file.

app/Providers/Filament/AdminPanelProvider.php:

// ...
use Filament\Navigation\NavigationItem;
 
class AdminPanelProvider extends PanelProvider
{
public function panel(Panel $panel): Panel
{
return $panel
// ... other methods ->xxxxx()
->navigationItems([
NavigationItem::make('About us')
->url('https://laraveldaily.com', shouldOpenInNewTab: true)
->icon('heroicon-o-link')
]);
}
}

And that's it! Here's the visual result:

Read more about navigation customization in the official Filament docs.

Looking for a specific icon for the menu item? Here's the Blade UI Kit list to search from.


If you want more Filament examples, you can find more real-life projects on our FilamentExamples.com.

avatar

How to add custom link to NavigationGroup ?

Like our articles?

Become a Premium Member for $129/year or $29/month
What else you will get:
  • 68 courses (1183 lessons, total 43 h 18 min)
  • 90 long-form tutorials (one new every week)
  • access to project repositories
  • access to private Discord

Recent New Courses