HTML attributes provide additional information about HTML elements.

link: <a href="<https://www.w3schools.com>">This is a link</a>

The link's destination is specified in the href attribute.

Attributes are used to provide additional information about HTML elements.


<img src="w3schools.jpg" alt="W3Schools.com" width="104" height="142">

HTML images are defined with the <img> tag.

The source file (src), alternative text (alt), width, and height are provided as attributes:


HTML attributes provide additional information about HTML elements.

<p style="color:red;">This is a red paragraph.</p>

https://s3-us-west-2.amazonaws.com/secure.notion-static.com/e82c9d5b-4383-4a08-9b81-44091e76b63d/Untitled.png

<pre> to preserve all the spaces and newlines.


Style

<tagname style="property:value;">

The CSS text-align property defines the horizontal text alignment for an HTML element:

<p style="text-align:center;">Centered paragraph.</p>