Open external links in a new window


Opens external links (starting with http:// or https://) in a separate browser window (or tab). You can also specify certain URLs that should either be forced to open in a new window or ignored.
The plugin produces XHTML Strict compliant code and is also search engine optimized (SEO).
This is done using JavaScript’s

Most other plugins perform a hack by altering the target parameter (i.e. <a href="http://somewhere.example" target="_blank">). That method is not XHTML Strict compliant.
This plugin handles the links client-side, which lets search engines follow the links properly. Also, if a browser does not support JavaScript, the plugin is simply inactive, and does not result in any errors.

Inspired by the Zap_NewWindow-plugin by Tom Köhler.
The banner is a photo by Monja Da Riva.

Danish by Kristian Risager Larsen.
Dutch by Paul Staring
Lithuanian by Vincent G.
Other translations will be appreciated!

Known bugs
* The plugin conflicts with other plugins that change the links’ `onClick´-attribute.


  1. Copy the plugin to /wp-content/plugins/
  2. Activate the plugin.
  3. Eventually, change the settings in Settings->External links.



My Social Media links REFUSED to responds to target_blank – was pulling my hair out with coding – this is great!


Thank you so much, it works fantastic. None of the other similar plugins worked for me at all.

Wow! No way! I wasted 8 months on looking a plugin like this!!!

Wow! No way! I wasted 8 months on looking a plugin like this that can work with woo commerce and nothing worked but this one! This plugin is definitely one of the best plugin I have ever used. This developer is obviously a genius…

Thank you! A donation will follow soon… i need to dig in to the plugin more 🙂


I’m using a theme where social media icons can’t be set to open in a new tab…….not even when creating new header and footer php files in a child theme with custom code from theme authors. Anyway, long story short, this plugin works perfectly and my social media icons now open a new browser tab…..sweet! Thanks!!

Read all 32 reviews

Contributors & Developers

“Open external links in a new window” is open source software. The following people have contributed to this plugin.




Verified compatibility with WordPress 4.0
Added: Plugin logo for WordPress 4.0
Added: Dutch translation.


Added: Possibility to force and ignore user-defined strings in URLs. This feature has been requested.
Added: Lithuanian and Danish translation.


Added: Translation-ready.


Fixed: Deprecation warning (Thanks to boo1865)


Changed: Better practice for opening links. The plugin now uses the onClick-attribute instead of writing JavaScript directly into the href-attribute. This enables users to right-click the link and open in a new window/tab, save the target etc.


Fixed: Removes target attribute from links instead of setting the attribute to null. (Thanks to crashnet)


Fixed: Credits to Tom Köhler (Charset).
Fixed: Links.


Initial release.