Next.js Learn login fails with 404 and CORS error on 'rsc' header

I am unable to log into the Next.js learning portal located at Learn Next.js | Next.js by Vercel - The React Framework . After successfully logging into my Vercel account, I am taken straight to a 404 error page. I see the following error logged in the console:

Error:

Access to fetch at 'https://vercel.com/oauth/authorize?client_id=<redacted>&redirect_uri=https%3A%2F%2Fnextjs.org%2Fapi%2Fauth%2Fcallback&state=<redacted>&nonce=<redacted>&code_challenge=<redacted>&code_challenge_method=S256&response_type=code&scope=openid+offline_access' (redirected from 'https://nextjs.org/api/auth/authorize?slug=react-foundations&_rsc=<redacted>') from origin 'https://nextjs.org' has been blocked by CORS policy: Request header field 'rsc' is not allowed by Access-Control-Allow-Headers in preflight response.

Environment

  • Browsers: Edge and Safari (MacBook M2)
  • Accounts: Multiple Vercel accounts tested

This seemed to be working fine a week or so ago.

Thanks

There’s another community post with 404 debugging tips that might be helpful. Please give these solutions a try and let us know how it goes.

A human should be around soon to offer more advice. But you can also get helpful information quickly by asking v0.

the “Debugging 404 Errors” is pretty old, and talks about generic use cases mostly related to deployments on Vercel. The problem reported here is specificly about connecting nextjs.org and vercel.com. I came across this error when going through the Next.js fundamentals course and trying to sign in to vercel to preserve my learning progress. Whatever configuration changes are required it is between nextjs and vercel.