Next.js 16 async params is the breaking change to check first when you move from 15 to 16. Next.js 15 made params , searchParams , cookies() and headers() asynchronous but still allowed synchronous access during a compatibility period. Next.js 16 removes that. I hit this while porting the blog system on my portfolio to Next.js 16. Below is the fixed version of every common call site, the codemod, and what the codemod does not convert.
The short answer
Await them. In Next.js 16, params and searchParams are Promises, and cookies() , headers() and draftMode() return Promises.
const { slug } = await params ; const { page } = await searchParams ; const token = ( await cookies ()). get ( " token " );
Enter fullscreen mode
Exit fullscreen mode
Then run npx @next/codemod@canary next-async-request-api . and search your code for @next-codemod-error . Everything below targets Next.js 16 (App Router). On 15, synchronous access still works with a warning.…