Resolving "Built-in next/font" Error in Next.js
This document offers a detailed guide on fixing the "Built-in `next/font`" error in Next.js, which typically occurs when you're still using the `@next/font` package in Next.js 13.2 and later.
next/font will automatically optimize your fonts (including custom fonts) and remove external network requests for improved privacy and performance.
next/font" error is triggered when the
@next/font package is still installed and used in your Next.js application.
From version 13.2 onward,
next/font has been built into Next.js, making the
@next/font package redundant. The
@next/font package will be completely removed in Next.js 14.
To resolve this issue, you need to uninstall
@next/font and replace all
@next/font imports with
next/font in your project. This can be done automatically using the
npx @next/codemod built-in-next-font .