documentation/guides/docs/configuration/migration.md
With Docs 2.0 we've completely started from scratch. We tried to stick to the patterns we already had, so they way you set it up is not too different.
TL;DR
Migrate your scalar.config.json with: npx @scalar/cli project upgrade
[relative Markdown paths](../your-other-file.md)<head> customization (meta tags, scripts, stylesheets)$ref resolutionIf you created a project before February 2026, you probably use Docs 1.0:
// scalar.config.json (Docs 1.0)
{
"$schema": "https://cdn.scalar.com/schema/scalar-config.json",
"siteConfig": {
// …
},
"guides": [
// …
],
"references": [
// …
],
}
For Docs 2.0 we still use the scalar.config.json, but the structure changed a bit:
// scalar.config.json (Docs 2.0)
{
"$schema": "https://registry.scalar.com/@scalar/schemas/config",
"scalar": "2.0.0",
"info": {
// …
},
"siteConfig": {
// …
},
"navigation": {
"routes": {
// …
}
}
}
Actually, under the hood, you’re using Docs Version 2 already.
If you want to actually use new features and upgrade your configuration file use the CLI to upgrade:
npx @scalar/cli project upgrade
Check how your documentation looks with:
npx @scalar/cli project preview
If it's good, commit and push the upgraded configuration to your repository – done!