Audit URL
Resolves to the same URL as the Panel's open button – draft pages, custom hostnames, and per-language variants are all in scope.
Model Support
The plugin works with any Kirby model that has a previewUrl method:
- Pages: Analyze individual page content.
- Site: Check site-level SEO (homepage, etc.).
Custom Target URL
In certain cases, you might want to customize the target URL used to generate the SEO report. This can be done by adding a preview option to the model's blueprint:
options:
preview: https://getkirby.com/features/developers
sections:
seoAudit:
type: seo-audit
This is particularly useful for:
- Analyzing external URLs
- Testing staging environments
- Checking specific URL variations
Cross-Origin Analysis
When the preview URL origin differs from the Panel origin, the Panel posts the page's Panel path to the plugin's proxy route, and Kirby resolves the preview URL server-side before fetching it – that avoids CORS errors. Same-origin URLs are fetched directly in the browser.
Language-Specific Analysis
Switching the Panel language refetches the preview URL, so a secondary language is analyzed against its translated page.
lang attribute of the rendered page – see Assessments for SEO and Readability.Debugging URL Resolution
To understand which URL is being analyzed, you can enable debug logging:
return [
'johannschopplich.seo-audit' => [
'logLevel' => 'info'
]
];
This will log information about the resolved preview URL and the HTML extracted for analysis. You can inspect these logs in your browser's developer console.