The Deprecated <font> Tag
In the mid-90s, the web was a wild place. Before CSS became the standard for styling, HTML tags had to handle both structure and presentation. The <font> tag was one such tool.
What did it do?
The <font> tag was used to style text inline. It wrapped text content and allowed you to define the text color, font size, and font family for that specific text. Attributes included size, color, and face. Unlike <basefont>, <font> required a closing tag and was an inline element.
Why is it gone?
It violated the principle of Separation of Concerns. HTML should describe what content is (paragraph, heading), not how it looks (red, size 5). CSS was invented to handle the "how". Consequently, <font> was deprecated in HTML 4.01 and completely removed in HTML5.
The Modern Alternative
Today, you should use CSS for styling. For inline styling, use the span element with CSS: <span style="color: red; font-size: 20px;">styled text</span>
Or better yet, use CSS classes: <span class="highlight">styled text</span> with CSS rules.
