Home → References → HTML Tags →
HTML Tag: link
Defines a link to an external resource. It is most commonly used to link a CSS file to an HTML document.
link must appear within the head element.
HTML Dog is hosted by Titan Internet
Required Attributes
- None.
Optional Attributes
hrefcan be used to specify the target of a link.charsetcan be used to specify the character set of the target of a link.hreflangcan be used to specify the language (in the form of a language code) of the target of a link. It should only be used whenhrefis also used.typecan be used to specify the MIME type of the target of a link.relcan be used to specify the relationship of the target of the link to the current page.revcan be used to specify the relationship of the current page to the target of the link.mediacan be used to specify which media the link is associated to. A value such asscreen,print,projection,braille,speechorallcan be used or a combination in a comma-separated list.- Common attributes
Example
<link rel="stylesheet" type="text/css" href="default.css" />

