Don’t use target=_blank
Written May 26, 2009. 23 comments.
Despite what you may have heard from your boss who doubles as a ‘usability expert’, people actually like to have control over their browser. One of the most infuriating ways to annoy web surfers (me included) is to make decisions for us, and if you’re forcing external links into new windows or tabs then you’re doing exactly that.
The thing is, I know how to use my browser, and so do others. If I want to open a link into a new tab, I’ll hold CTRL while I click. Or if I’ve got a mug of Milo in one hand I will select ‘open in new tab’ from the context menu.
But even if you have the evidence to suggest the opposite, you have no reason to believe they would prefer you force links to open in new windows for them anyway. So why do it?
For the benefit of the noobs who have been following this blog, opening a link in new window is accomplished by:
<a href="http://www.w3c.org" target="_blank">I don't care about usability</a>
If you’re using XHTML strict then you’re probably already aware that target=”_blank” has been deprecated so you shouldn’t be using it unless you want to invalidate the document anyway. But if you’re one of those developers who uses JavaScript to force links into a new window just so you’re document can still validate (because you didn’t have to use target=”_blank”), then you’re more evil because you’ve actually gone to the extra effort to annoy the user.
For the record there is no actual usability standard that I’m aware of that forbids forcing links into a new window, only the W3C standard. But it’s a well known usability notion that opening links into new windows is pointless and annoying.
Why do they do it?
A lot of web developers force new windows under the misguided theory that the user will stay on their web site.
Here’s the thing. If someone wants to leave your web site, they will leave your site. That’s their choice, not yours. If you force all your external links into a new tab or window, they are still going to leave your web site if they’ve made the choice to do so. Your site still being in plain view isn’t going to change that fact. I’m sorry, but it isn’t.
Need more convincing? A quick Google search led to me to “The top 10 web design mistakes of 1999“, where number 2 lists “Opening new browser windows”.
Now before you cry “But that was 1999!” consider this: Even back then, during a time when designers still used tables and 1 pixel spacer gifs for layout and the Flash intro epidemic was rampant, some common sense prevailed to know that forcing new windows was just plain wrong.
Take control
I all fairness, some developers force new windows because their boss wanted it that way or because the marketing guy (who still keeps a first edition copy of ‘marketing in the 90′s’ behind his desk) says it would improve sales. If you fall into this category, I feel your pain.
If nothing else remember this: you’re the one they pay to “know about all that web stuff”, so if it’s against your better judgement, make it a point to explain error of their way.
Start of page
But everyone know his best ;)
Good topic web guy.
And now you all got me thinking.. To _blank or not to _blank :)
You see, my point is, no matter do you want to have your visitor stay on your site, visitors can find annoying fact that their current page is being interrupted.
BTW, about 95% of Internet users in Bosnia, Croatia, Serbia and similar, my targeted area (I live in BiH, so…), don’t even know about those functions (CTRL + Click, middle click etc.)..
p.s.
Web guy, I don’t see practical use of the ‘captcha’ below. It’s REALLY EASY to make computer see what’s on the picture (well, not really what’s on it, but by looking into HTML), and write in comment.
Good luck!
Love your blog!
Regarding the CAPTCHA, the HTML doesn’t give away the answer (the name of the character) – it’s only a number each time – like 5.jpg for example – which will fail if you enter just a number anyway. The only way I see it can be beaten is with facial recognition software, or by manual spammers who look for every one of the characters that appear and then use all those names in an automated script.
Unless you’ve somehow gained access to my PHP script that contains all the answers :-)
I’ve used this system on my other blog without a single spam hit for over a year now.
Web guy: I can think of one time when it’s probably ok to open a new window and that’s if the link advises them first something like…
“Click here to visit Digg (opens in a new window)”
What do you think?
I love what I see here Web guy! Is this your own design?
Probably no one wanted to spam you. If you understand what I’m saying, someone could make a script that binds characters to their numbers, like an array $spam = array(1.jpg =>’superman’, 2.jpg =>’spiderman’); and so on.. if you know what I mean..
Well, probably you’ll never need some higher security because why would anyone want to spam a nice web guy :) , but I am just saying it’s possible :)
Keep up the good work ;)
In any event I loathe CAPTCHA from a usability perspective so I’ve tried to make it as easy as possible. If I get some spare time I will see if I can implement the change – or if I start to get spammed – which ever comes first ;-)
Thanks web guy – you are the man!
in my opinion it is some times very comfortable to open a new tab with target_blank, cause if i click on a link to a new website and the new site opens in the same tab then i must return with the browsers back button and go to the same link and click on it with right mouse button and choose load in new tab…. this is wasting time… click on a link, open new tab and all is fine, cause a i have the old site and the new site open.
And this Are you human verification is becoming a challenge.. I thought it was Anakin and then this frog appears whoah.. U Should put anime too if that’s the case.
altough it is sometimes hard to confince some customers / webdesigners to not use it :-(.
I find it usefull to also provide the external links with an image allowing the user to easily spot that it is actually an external link.
I use the image which is also used on the wikipedia and quit some other websites:
http://en.wikipedia.org/wiki/Wikipedia:Manual_of_Style#External_links
“_blank” is dead to me and I never want it back on my websites or on the websites I create for customers :-)
STRICT + valid is the way I role, I just have to be stubern / poot my foot down and explain it well to why I am disallowing them (my customers) to use that option, even if it will cost me an also stubern / “thinks who know it all” customer and that is sometimes hard :-)
The image I provide is just an extra way of informing the visitors that they are gonna open an external page so they can do with it whatever they want and so they won’t get “surprised” by a all new page on visiting :-).
I believe this goes to the issue of usability. While most people have a tabbed browser now, don’t assume that they:
1) like using tabs
2) know how to use tabs
3) want to use tabs
4) have a tab capable browser
Given that users are still able to get around your site just fine without opening stuff in new tabs, there’s really no justifiable reason for designers to be forcing them, other than to match their own personal ‘tab politics’.
Me personally, I let the user decide what they want to do with links on my site. I have no business dictating to them how to get around the interwebs :-)