Fix — Add localhost to Sanity CORS
Go to sanity.io/manage
Select your brands-digitals project
Click API in the left sidebar
Scroll to CORS Origins
Click Add CORS Origin
Add exactly: http://localhost:3000
Check Allow credentials ✅
Click Save
Also add these while you're there so you don't hit this again on deployment:
http://localhost:3000 ✅ Allow credentials https://brandsdigitals.com.ng ✅ Allow credentials https://brandsdigitals.vercel.app ✅ Allow credentials
Then check your .env.local
The URL in the error shows v2026-04-01 as your API version. Make sure your env file matches:
env
NEXT_PUBLIC_SANITY_API_VERSION=2026-04-01
Whatever version is in that URL — use that exact string in your env variable.
After savi

ng CORS, restart your dev server
bash
# Stop the server (Ctrl+C) then: npm run dev
That should clear it. The request will go through once Sanity whitelists your localhost origin.

Mercien Damilare
Bio
Want results like these?
Your transformation starts with a single conversation. Let's build your next success story.
