freecourses.digital
Lesson progress: 0 of 3 activities done
All lessons in HTML Basics for Beginners Lesson 3.3 of 34

Module 10: Practice Project and Validation

  1. 10.1Build a simple HTML website

Bold, emphasis, and text formatting

In this lesson

  • strong vs b, em vs i
  • Highlighting with mark and side notes with small
  • sup, sub, code, and abbr
  • Quotes with blockquote and q, and HTML entities

Short answer

Use <strong> for important text and <em> for stressed emphasis. Both carry meaning that screen readers and search engines can notice. <b> and <i> only change the look, so save them for things like product names or foreign words. Other inline tags handle highlights, fine print, code, quotes, and special characters.

strong vs b, em vs i

TagMeaningExample use
<strong>Strong importanceWarning: the road is closed.
<em>Stress emphasisI said Tuesday, not Thursday.
<b>Draw attention, no extra importanceProduct names in a review
<i>Alternate voiceForeign words like pasalubong

Both pairs look the same by default, bold and italic. The difference is meaning, which is the heart of semantic HTML.

Other inline formatting

<p><mark>Sale ends Sunday</mark></p>
<p><small>Prices include VAT.</small></p>
<p>Water is H<sub>2</sub>O. Area is 25 m<sup>2</sup>.</p>
<p>Type <code>Ctrl + S</code> to save.</p>
<p><abbr title="Department of Trade and Industry">DTI</abbr> registered.</p>
<p>Was <del>₱500</del> now <ins>₱399</ins>.</p>

Quotes

<blockquote cite="https://example.com/review">
  <p>Best pili tarts in Albay!</p>
</blockquote>
<p>She said, <q>See you at the plaza.</q></p>

<blockquote> is for longer quotes in their own block, like a customer testimonial. <q> adds quotation marks around a short quote inside a sentence.

HTML entities

Some characters have special meaning in HTML. To show them as text, use entities:

CharacterEntity
<&lt;
>&gt;
&&amp;
©&copy;
non-breaking space&nbsp;

With UTF-8 you can type ₱ and ñ directly, so you only need entities for the first three and for nbsp.

Try it: format a promo

Make the deadline strong, highlight the discount with mark, strike the old price with del, and put the fine print in small.

Live preview

Quick quiz

1. Which tag marks strong importance?
2. Which tag fits a foreign word?
3. How do you show a less than sign as text?
4. Which tag fits a customer testimonial block?

Common mistakes

  • Bolding everything. If everything is strong, nothing stands out.
  • Using em just for italics. Use em only when stress changes the meaning.
  • Using u for emphasis. Underlined text looks like a link. Avoid it.

Your action

Tick each item when you can do it. Your progress saves on this device.

Key terms

<strong>
Text with strong importance.
<em>
Text with stress emphasis.
<mark>
Highlighted text.
<blockquote>
A block quotation from another source.
HTML entity
A code like &lt; that displays a reserved character.
Inline element
An element that sits inside a line of text, like strong or a.

Questions beginners ask

Does strong help SEO?

Barely. Use it for readers, not for ranking.

Is <b> deprecated?

No. It is valid in modern HTML with a narrower meaning.

How do I show HTML code on a page?

Wrap it in <code> or <pre><code> and escape < as &lt;.

Related lessons

Need a website built or fixed while you practice? The team at Remar Digital can help.