X
HOME HTML CSS JAVASCRIPT SQL PHP JQUERY ANGULAR BOOTSTRAP XML ASP.NET MORE...
REFERENCES | EXAMPLES | FORUM | ABOUT

HTML <a> target Attribute

HTML a Tag Reference HTML <a> tag

Example

The target attribute specifies where to open the linked document:

<a href="http://www.w3schools.com" target="_blank">Visit W3Schools</a>

Try it Yourself »

Definition and Usage

The target attribute specifies where to open the linked document.


Browser Support

Attribute
target Yes Yes Yes Yes Yes


Syntax

<a target="_blank|_self|_parent|_top|framename">

Attribute Values

Value Description
_blank Opens the linked document in a new window or tab
_self Opens the linked document in the same frame as it was clicked (this is default)
_parent Opens the linked document in the parent frame
_top Opens the linked document in the full body of the window
framename Opens the linked document in a named frame


HTML a Tag Reference HTML <a> tag

Your suggestion:

Close [X]

Thank You For Helping Us!

Your message has been sent to W3Schools.

Close [X]
Search w3schools.com:

WEB HOSTING

UK Reseller Hosting

WEB BUILDING

Download XML Editor FREE Website BUILDER Free HTML5 Templates

SHARE THIS PAGE

facebook