SEO Suite Pro by Mustafa Afat
CommunityThis package allows you to seamlessly integrate and manage SEO features, making your project more search engine friendly.
filament/
namespace. Review the source and install at your own risk. Found
malware or an unresolved security issue the author won't
address?
Report it
.
Author:
Mustafa Afat
Documentation
- Features
- Requirements
- Installation
- Usage
- Result 🤩
- Default Values
- Upgrading
- Roadmap
- Testing
- Changelog
- Contributing
- Security Vulnerabilities
- Credits
- License
Elevate your Filament project with SEO Suite, leveraging the artesaos/seotools package for enhanced search engine optimization.
This package allows you to seamlessly integrate and manage SEO features, making your project more search engine friendly.

#Features
- Ready-to-use form component: Easily add SEO settings to your resources.
- Set title and meta tags: Quickly configure title and meta tags.
- Social media integration: Support for Twitter Cards and Open Graph.
- Multiple open graph types: Supports 3 open graph types: article, book, profile.
- Multiple twitter card types: Supports 4 twitter card types: summary, summary_large_image, app, player.
- Fallback ready: Ensures robust default values.
- Ready-to-translate: Supports multiple languages.
#Requirements
| SEO Suite | PHP | Laravel | Filament |
|---|---|---|---|
| 1.1.x | 8.2+ | 11, 12, 13 | 3.2+, 4, 5 |
| 1.0.x | 8.1+ | 10, 11 | 3.2+ |
The same release works on Filament 3, 4 and 5, so you can upgrade Filament without changing the SEO Suite version.
#Installation
To install the package you should add the following lines to your composer.json file in the repositories key in order to get access to the private package:
{
"repositories": [
{
"type": "composer",
"url": "https://seo-suite-for-filamentphp.composer.sh"
}
]
}
Next, you should require the package via the command line. You will be prompted for your username (which is your e-mail) and your password (which is your license key, e.g. f6183128-5477-4f38-45b1-4842484f4a842:ProjectName).
composer require afatmustafa/seo-suite
Note: This package uses artesaos/seotools behind the scenes, you may also need to follow the installation steps there.
You can publish and run the migrations with:
php artisan vendor:publish --tag="seo-suite-migrations"
php artisan migrate
You can publish the config file with (optional):
php artisan vendor:publish --tag="seo-suite-config"
This is the contents of the published config file:
return [
/**
* Override the SEO Model to perform custom actions.
*/
'model' => \Afatmustafa\SeoSuite\Models\SeoSuite::class,
'table_name' => 'seo_suite',
/*
|--------------------------------------------------------------------------
| Enabled features.
| If you want to disable a feature, set it to false.
|--------------------------------------------------------------------------
*/
'features' => [
'general' => [
'enabled' => true,
'fields' => [
'title' => true,
'description' => true,
],
],
'advanced' => [
'enabled' => true,
'fields' => [
'canonical' => true,
'noindex' => true,
'nofollow' => true,
'metas' => true,
],
],
'opengraph' => [
'enabled' => true,
'fields' => [
'og_title' => true,
'og_description' => true,
'og_type' => true,
'og_properties' => true,
],
],
'x' => [
'enabled' => true,
'fields' => [
'x_card_type' => true,
'x_title' => true,
'x_site' => true,
],
],
],
// SEO fallbacks
'fallbacks' => [
'title' => 'title',
'description' => 'description',
'og_type' => 'article',
],
];
Optionally, you can publish the translations using
php artisan vendor:publish --tag="seo-suite-translations"
The package currently supports both English and Turkish languages. If you want to add a new language, feel free to create a PR.
#Usage
#In Your Model
First, you need to add the Afatmustafa\SeoSuite\Models\Traits\InteractsWithSeoSuite trait to your model.
If you want to edit your SEO Fallbacks on a model basis, you can edit them by adding a property called $seoFallbacks to your model.
// App/Models/Page.php
class Page extends Model {
use Afatmustafa\SeoSuite\Models\Traits\InteractsWithSeoSuite;
protected ?array $seoFallbacks = [
'title' => 'name',
'description' => 'excerpt'
];
}
#In Your Resource
To use the form component, add \Afatmustafa\SeoSuite\SeoSuite::make() to your resource form. It saves to the seoSuite relationship by itself.
Filament 4 and 5:
// App\Filament\Resources\Pages\PageResource.php
use Filament\Schemas\Components\Section;
use Filament\Schemas\Schema;
public static function form(Schema $schema): Schema
{
return $schema
->components([
// ...
Section::make('SEO Settings')
->schema([
\Afatmustafa\SeoSuite\SeoSuite::make(),
])
->columnSpanFull(),
]);
}
Filament 3:
// App\Filament\Resources\PageResource.php
use Filament\Forms;
use Filament\Forms\Form;
public static function form(Form $form): Form
{
return $form
->schema([
// ...
Forms\Components\Section::make('SEO Settings')
->schema([
\Afatmustafa\SeoSuite\SeoSuite::make(),
]),
]);
}
#In Your Frontend Controller
In your controller you can add the trait Afatmustafa\SeoSuite\Traits\SetsSeoSuite and then use the setsSeo() function to set the meta tags.
// App\Http\Controllers\Site\PageController.php
class PageController extends Controller
{
use \Afatmustafa\SeoSuite\Traits\SetsSeoSuite;
public function home() {
$page = \App\Models\Page::whereTemplate('homepage')->first();
$this->setsSeo($page);
return view('site.pages.home');
}
}
#In Your View
You can use the SEO::generate() to render the SEO tags in your view.
<html>
<head>
{!! SEO::generate() !!}
</head>
<body>
</body>
</html>
#Result 🤩
#Frontend Result
Finally, this is how your meta tags will look like in the frontend.
<title>Taking Notes on Taking Notes - Afat.me</title>
<meta name="description" content="I’ll share my personal journey through various note-taking applications, from Notion to Obsidian, highlighting the pros, cons, and humorous moments along the way.">
<meta name="google-site-verification" content="lxqpno64dlwihrdkvbgwtzzha0poig">
<link rel="canonical" href="https://afat.me">
<meta property="og:title" content="My Note-Taking Apps and Experiences">
<meta property="og:description" content="Taking notes and being organized is crucial for boosting your productivity as a developer. There are many tools available for taking notes, such as Notion, Craft, and Obsidian. These tools can help you organize your ideas, projects, and daily tasks.">
<meta property="og:type" content="article">
<meta property="article:tag" content="development">
<meta property="article:author:gender" content="male">
<meta property="article:author:username" content="afatmustafa">
<meta property="article:author:last_name" content="Afat">
<meta property="article:author:first_name" content="Mustafa">
<meta property="article:modified_time" content="2024-08-01 00:00:00">
<meta property="article:published_time" content="2024-08-01 00:00:00">
<meta name="twitter:title" content="My Note-Taking Apps and Experiences">
<meta name="twitter:description" content="I’ll share my personal journey through various note-taking applications, from Notion to Obsidian, highlighting the pros, cons, and humorous moments along the way.">
<meta name="twitter:site" content="https://afat.me">
<meta name="twitter:card" content="summary">
<script type="application/ld+json">{"@context":"https://schema.org","@type":"WebPage","name":"Taking Notes on Taking Notes","description":"I’ll share my personal journey through various note-taking applications, from Notion to Obsidian, highlighting the pros, cons, and humorous moments along the way."}</script>
#Panel Result

#Supported Open Graph Types

#Default Values
You can set default values for your SEO tags in the artesaos/seotools config file.
// config/seotools.php
#Upgrading
#From 1.0.x to 1.1.x
1.1 is a drop-in update: the database, config, translations and public API are unchanged. Run composer update afatmustafa/seo-suite.
- PHP 8.2 and Laravel 11 are now the minimum. On PHP 8.1 or Laravel 10, keep using 1.0.x.
- If you upgrade Filament from 3 to 4 or 5, update your own resources with the Filament upgrade guide.
SeoSuite::make()needs no changes. - SEO fields now reject values longer than 255 characters (the length of their database columns) with a validation error instead of a database error.
#Roadmap
- Filament 4 and 5 support
- Laravel 12 and 13 support
- OG image and X (Twitter) card image support, optionally with spatie/laravel-medialibrary
- Admin page for default SEO values like title prefix and suffix, default image, X handle
- JSON-LD support
- More Open Graph types (music and video)
- Multi-language support with spatie/laravel-translatable
#Testing
composer test
#Changelog
Please see CHANGELOG for more information on what has changed recently.
#Contributing
Please see CONTRIBUTING for details.
#Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
#Credits
#License
The MIT License (MIT).
The author
Mustafa is a highly motivated Backend Developer with extensive experience in PHP and Laravel. His committed to achieving high levels of efficiency, and continually seek ways to optimize processes. His passion lies in driving innovation and delivering high-quality projects through the effective use of technology.
From the same author
Featured Plugins
A selection of plugins curated by the Filament team
Sharp Theme
A theme that gives panels a precise, technical look with square corners, strong borders, and clear contrast.
Filament
Advanced Tables (formerly Filter Sets)
Supercharge your tables with powerful features like user-customizable views, quick filters, multi-column sorting, advanced table searching, convenient view management, and more. Compatible with Resource Panel Tables, Relation Managers, Table Widgets, and Table Builder!
Kenneth Sese
Blueprint
Filament Blueprint is a premium Laravel Boost extension that helps AI agents produce accurate, detailed implementation plans and security reports for Filament apps.
Filament