
I am using appwrite for the first time. I tried the example in the documentation. However, I got the following error.I am using appwrite for the first time. I tried the example in the documentation. However, I got the following error. here is the error,
Access to XMLHttpRequest at 'http://hl-appwriter.buildapi.cyou/v1/account' from origin 'http://localhost:3000' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: Redirect is not allowed for a preflight request.
anyone have idea how to fix this ? Thank you !!!

Did you add your client app as a web platform to your project?

yes

Also, make sure you're using https for your endpoint

I originally used http, but after your response I changed it to https. I got a solution to my problem. Thank you for your support

[SOLVED] CORS Error In React JS
Recommended threads
- Getting `net::ERR_CERT_AUTHORITY_INVALID...
I've set up Appwrite via Coolify on my VPS, but all the Functions and Sites I deploy give a `net::ERR_CERT_AUTHORITY_INVALID` error. I am happy to provide whate...
- insecure connection on Appwrite sites de...
This only happens in microsoft edge for some reason. I inspected all network requests and they are all requesting https properly. All other browsers work fine. ...
- Appwrite SSR Google OAuth (Invalid Redir...
I was following the documentation till here: https://appwrite.io/docs/tutorials/nextjs-ssr-auth/step-7#oauth-form Getting 301 err, I tried creating a new proje...
