I have seen that most websites usually open the "login with Facebook" page in a popup window, but there are also some websites (like stackexchange) that just redirect the browser without opening a popup.

Knowing that it's always "bad" to open noisy popups, just redirecting the user away from your page doesn't sound like the best idea either. Is there any alternative way to do this? Or in the worst case, which is "less harmful" way to do it? Popup or redirection?

3 Answers 3


Redirection works well for a number of reasons:

  • Users can see that they actually log in on the service's (twitter, facebook, you name it) website. That creates trust between the user and your website (you use a trusted third party to log in), and is also technically secure (as in you don't send the credentials to fb or twitter, thus enabling a man-in-the-middle attack, but users directly fill them in at fb/twitter/etc). The frustration of a potentially leaked password is greater than the one from a redirect every time.
  • Pop-ups might get messy when a user is navigating on a mobile browser. The big variance in screen resolutions, browser widths, native popups, etc., is a headache you might want to avoid.

In conclusion, the idea is that you don't take responsibility for the security of the login, but fb does, and you communicate that to the users, so they trust you; plus, you do that in a way that works well across devices and browsers.

  • also i've noticed that most popup blockers/browsers will prevent the popup from being shown, leaving the user confused.
    – astroanu
    Commented Aug 18, 2015 at 6:01

I think the reason most offer the redirect is because you need to refresh the page to show the logged in features. However I personally prefer neither of those solutions, I think clicking on login should then show a new element within the page. Like if you click "add comment" under this post.

This way you are allowing the user to login right there and then, or indeed go straight back to what they were doing with no fuss.

  • 5
    I would never login using my username\password to a form in some website that claims it's a facebook\twitter\gmail login.
    – tamir
    Commented Sep 26, 2016 at 15:01

(If I've understood the problem here) I would have thought that these days, offering a simple html anchor link that opens a new browser window or tab offers the user the best cross-device experience; perhaps using the still available (if once maligned) target="_blank" attribute when discussing pop-ups?

The user then has no browser alerts over "complicated" custom windows/pop-ups to worry over, can organize their browser tabs/windows how THEY want, and still remain within your domain. It also reduces the complexity of your cases for determining a user's device, screen/window size, focus, etc. Pop-ups should only be employed on closed platforms to which the user has "bought in" to them - IMOHO.

But if this is a logon to effect a like or share of content from your site then I see no reason to use a new window, pop-up, or browser tab to break the user flow through your content and you have every justification to keep the user fully engaged within your own page. I agree with Tim that an unobtrusive layer/element in your own - and the users' flow is the better user experience, and probably meets their glowingly sophisticated expectations, in any case.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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