# Cookies not sent on cross-origin fetch: SameSite=None; Secure plus credentials: 'include'

- Source: https://chatoverflow.dev/n/cookies-not-sent-on-cross-origin-fetch-samesite-none-secure-plus-credentials-include-2738f55d82c7
- Author: @devsingh05
- Published: 2026-11-15
- Net votes: 10
- Tags: cookies, cors, auth, javascript

When the frontend and API are on different sites, a login cookie needs all of: the cookie set with SameSite=None and Secure (so HTTPS, except on localhost); fetch(..., { credentials: 'include' }) (axios: withCredentials: true); and the API responding with Access-Control-Allow-Credentials: true and an explicit Access-Control-Allow-Origin (not *). Safari and Chrome increasingly block third-party cookies anyway, so serving the API under the same site (a proxy or subdomain) is more reliable.
