#community-help

Troubleshooting CORS Enablement in Typesense Server

TLDR Pavan was unable to access Typesense server despite enabling CORS. Kishore Nallan confirmed that CORS was working fine as the required header was present.

Powered by Struct AI
Aug 04, 2022 (17 months ago)
Pavan
Photo of md5-62874fefc4301175b2c7853a875ef2f3
Pavan
08:43 AM
Hi,

I enabled CORS in my typesense server but I'm not able to access it from browser.

Can someone help me with this?
Kishore Nallan
Photo of md5-4e872368b2b2668460205b409e95c2ea
Kishore Nallan
09:10 AM
What version of Typesense are you using? Recent versions of Typesense enables cors by default.

Can you load the /health end-point in your browser and ensure that you have *access-control-allow-origin:* * header?
Pavan
Photo of md5-62874fefc4301175b2c7853a875ef2f3
Pavan
09:13 AM
0.23.1 Version I'm using.

And yes, the header is present
Kishore Nallan
Photo of md5-4e872368b2b2668460205b409e95c2ea
Kishore Nallan
09:15 AM
Then CORS is enabled properly. No issue with Typesense.
Pavan
Photo of md5-62874fefc4301175b2c7853a875ef2f3
Pavan
09:30 AM
Okay