SPA doesn't see cookie from keycloak-js / keycloak server?

Hello there!

I need some help with keycloak-js or keycloak itself problem with saving cookie.

My actual behavior, when I login with keycloak, all is ok until I refresh page, when I refresh, it redirects to login again.

I’ve noticed that cookies from keycloak are not available when path in set cookies after login is different from path when I am on my page. I know this is weird explanation, but as is.

Cookies during 3g throttled login

Cookies on my SPA page

What can be wrong? I’ll provide other details on purpose.

Thanks in advance for any help!

Probably fixed that with enabling silent check-sso method in keycloak-js library.