Sign up ×
Web Applications Stack Exchange is a question and answer site for power users of web applications. It's 100% free, no registration required.

For a while I've noticed that Google logins (or, at least, GMail logins) always redirect through to "" Is Google handling all logins from If so, why?

(wasn't sure if I should post this on webapps or superuser, so feel free to move this or tell me to move this to the appropriate site if necessary)

share|improve this question

1 Answer 1

up vote 5 down vote accepted

When you log into a Google site like GMail, Google also logs you into all your various accounts Google accounts - such as YouTube. In order to be logged into a site, Google sets a cookie in your browser.

This is fine for most of their properties which are on the * domain (,, etc). However a website can only set and read a cookie for it's own domain - can't set a cookie for To get around this, as part of the login process Google will redirect you through to log you into YouTube - and typically your country specific domain if you are outside the US (e.g. I get logged into as well).

The full login process is described in this SO answer, it dates from 2009 but most of it should still hold true.

share|improve this answer
ah, that makes sense, I had completely forgotten that cookies were handled on a per-domain basis :) thanks! – MatthewThepc Aug 22 '12 at 1:29

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.