← 문제 라이브러리
Security 입문 3분

CORS 오류: No 'Access-Control-Allow-Origin' header is present

검수된 문제무료
시나리오

app.example.com에서 API를 부르면 브라우저에서만 막히고, curl로는 잘 됩니다.

단서
브라우저 콘솔
Access to fetch at 'https://api.example.com/orders' from origin 'https://app.example.com'
has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present
on the requested resource.