I'm getting a CORS + 401 Error with Appwrite Authentication
Access to fetch at 'https://cloud.appwrite.io/v1/account/sessions/email' from origin 'https://my-custom-subdomain.appwrite.network' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. POST https://cloud.appwrite.io/v1/account/sessions/email net::ERR_FAILED 401 (Unauthorized)
Framework: Next.js 14 with Appwrite SDK
Authentication: Email/Password using account.createEmailPasswordSession()
Environment Variables:
NEXT_PUBLIC_APPWRITE_ENDPOINT=https://cloud.appwrite.io/v1
NEXT_PUBLIC_APPWRITE_PROJECT_ID=my-project-id
My Integrations > Platforms
Name|Platform type|Identifier|Last updated
My Project Name|Web|my-custom-subdomain.appwrite.network|3 days ago
localhost|Web|—|A few seconds ago
It works well in localhost.
What I've tried
https://appwrite.io/blog/post/cors-error
So, how to fix it?
Recommended threads
- CORS errors in Obsidian custom plugin
Hi, anyone here familiar with obsidian community plugins? In short: it's a local first note app which supports writing your own add-ons / plugin But I keep get...
- > AppwriteException: The requested servi...
When trying to read or write from my database I get the following error: > AppwriteException: The requested service is disabled. You can enable the service from...
- Courtesy limit reset for non-profit migr...
Hi Team! I'm the architect for a 501(c)(3) non-profit project (Aaria's Blue Elephant) and we just hit our Free plan Database Read limit (currently at 164%). Th...