---
title: "Preview URL"
description: "The analysis reads the page's preview URL, unsaved changes included – override the target per blueprint when you need a different one."
canonical_url: "https://kirby.tools/docs/seo-audit/guide/preview-url"
---

# Preview URL

> The analysis reads the page's preview URL, unsaved changes included – override the target per blueprint when you need a different one.

The analysis reads the preview URL of the version it looks at: the unsaved changes while the form differs from the published content, otherwise the published page. Draft pages, custom hostnames, and per-language variants are all in scope. A page without a preview URL cannot be analyzed: its blueprint sets `options.preview: false`, or the editor's role lacks the preview permission.

## Model Support

The plugin works with pages and the site:

- **Pages**: Analyze individual page content.
- **Site**: Analyze the site through its preview URL, the home page.

## 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:

```yaml [pages/default.yml]
options:
  preview: https://getkirby.com/features/developers

sections:
  seoAudit:
    type: seo-audit
```

While the form has unsaved changes, the URL carries Kirby's `_version=changes` and `_token` query, so a frontend that ignores them renders the published content.

This is particularly useful for:

- Analyzing external URLs
- Testing staging environments
- Analyzing specific URL variations

## Cross-Origin Analysis

A preview URL on the Panel's own origin is fetched by the browser. Any other origin is fetched by Kirby on the server, so CORS never applies – the [proxy settings](/docs/seo-audit/configuration/global#proxy-configuration) in the global configuration apply only to that fetch.

## Language-Specific Analysis

On multi-language sites, the analysis targets the preview URL of the language selected in the Panel, so a secondary language is analyzed against its translated page.

<callout color="info" icon="i-ri-information-line" to="/docs/seo-audit/guide/assessments#language-specific-features">

Which assessments run depends on the `lang` attribute of the rendered page – see **Assessments for SEO and Readability**.

</callout>

## Debugging URL Resolution

When the preview URL cannot be reached or returns an error status, the analysis stops with an error that names the URL actually fetched. The browser console always shows the URL the analysis starts from, which is the preview URL before any `urlResolver` rewrite. To see the HTML extracted from the fetched page, set [`logLevel`](/docs/seo-audit/configuration/local#loglevel) to `info`.

---

Every page of this site as Markdown: <https://kirby.tools/sitemap.md>
