CSS3 Selectors: Type selector

This entry is part 2 of 40 in the series CSS3 Selectors

A type selector represents an instance of the HTML element type in the document structure.

This is the simplest of the selectors.  An example is h2 and p illustrated in the example below.

<!DOCTYPE html>
<head lang="en">
    <meta charset="UTF-8">
        h2 {
            color: blue;

        p {
            font-family: 'Arial', 'Helvetica', 'SANS-SERIF';
<h2>Taylor Swift</h2>

<p> Swift moved to Nashville, Tennessee, at the age of 14 to pursue a career in country music.</p>