I’ve a django app running with gunicorn and nginx.
While making request from [ALL https] project.vercel.app
to backend.domain.com
works correctly.
But when i make request from domain.com
(Devtools>RequestHeader>Origin : www.domain.com
) to backend.domain.com
, it gives CORS error “has been blocked by CORS policy: No ‘Access-Control-Allow-Origin’ header is present on the requested resource.”.
Django CORS_ALLOWED_ORIGINS=(“www.domain.com”, “project.vercel.app”) BOTH ARE HTTPS
Both project.vercel.app and www.domain.com should work and cors error shouldn’t be seen cause it’s similar approach!
Man Ish is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.