Troubleshooting CORS Issues
Symptoms
- "Access-Control-Allow-Origin" errors in browser console
- Requests work in cURL but fail from a web application
- Preflight (OPTIONS) requests failing
Solutions
Simulation CORS Configuration
- Open simulation settings
- Go to CORS Configuration
- Add your application's origin (e.g.,
http://localhost:3000) - Save and test
Common CORS Origins to Allow
http://localhost:3000
http://localhost:5173
https://your-app.example.com
Wildcard Origin
For development, you can use * to allow all origins. Do not use this in production.
Missing Headers
Ensure these headers are included in CORS configuration:
AuthorizationContent-TypeX-Requested-With