SA-21/06, C-11, Asapur, Varanasi, UP support@kamaldnp.com +91 8318013442
HTML
1. HTML Introduction: What is HTML? Learn with Examples 2. Best Free HTML Editors: Notepad to VS Code for Beginners 3. HTML Basic Structure: Doctype, Head, Body Explained 4. HTML Elements Explained: Tags, Content & Empty Elements 5. HTML Attributes List: href, src, alt, width, title & More 6. HTML Headings h1 to h6: Which Heading Tag to Use When 7. HTML Paragraphs: p Tag, br Line Breaks & pre Text 8. HTML Style Attribute: Colour, Font Size & Alignment 9. HTML Text Formatting Tags: bold, italic, mark & More 10. HTML Comments: How to Add Notes & Hide Code in HTML 11. HTML Colors: Names, HEX, RGB & HSL Colour Codes 12. HTML CSS: Inline, Internal & External Stylesheets 13. HTML Links: a Tag, href, New Tab & Email Links 14. HTML Images: img Tag, src, alt, Width & Formats 15. HTML Favicon: Create & Add a Browser Tab Icon 16. HTML Title Tag: How to Write a Good Page Title 17. HTML Tables: table, tr, th, td, colspan & rowspan 18. HTML Lists: ul, ol, dl & Nested Lists Explained 19. HTML Block vs Inline Elements: div, p, span Explained 20. HTML Div Tag: Group Content & Build Page Layouts 21. HTML Class Attribute: Style Many Elements at Once 22. HTML id Attribute: Unique IDs, Links, CSS & JavaScript 23. HTML Iframes: Embed YouTube, Maps & Pages in HTML 24. HTML JavaScript: script Tag, Clicks & First Example 25. HTML File Paths: Relative vs Absolute Paths Explained 26. HTML Head Element: title, meta, charset & viewport 27. HTML Layout: header, nav, main, footer Page Structure 28. HTML Responsive Design: Viewport, Images & Media Queries 29. Semantic HTML Tags: header, nav, main, article & footer 30. HTML Forms: input, label, select, checkbox & Submit 31. HTML Entities: & < > © with Examples 32. HTML Audio & Video Tags: controls, source & Fallback 33. HTML Accessibility: alt Text, Labels, Landmarks & ARIA 34. HTML Meta Tags & SEO: charset, viewport, OG Tags 35. HTML Quotations: blockquote, q, cite, abbr & address
Final Test — Certificate ₹10
Try this code live
Lesson 9 of 35

HTML Text Formatting Tags: bold, italic, mark & More

3 min read · Free · No login needed

HTML has special tags that change how text looks and what it means. The two most used are <strong> for important text (shown bold) and <em> for emphasised text (shown italic).

Diagram — see how it fits together
Infographic: text formatting tags

Bold and italic — the right way

You may also see <b> and <i>. They look the same on screen — bold and italic — but they carry no meaning. <strong> tells the browser and search engines "this is important". <em> says "stress this word when reading aloud". Screen readers for blind users actually change their voice for strong and em, but not for b and i. So use strong and em in your pages.

Other useful formatting tags

  • <small> — smaller text, often used for fine print.
  • <mark> — highlighted text, like a yellow marker pen.
  • <del> — struck-through text (something removed).
  • <ins> — underlined text (something added).
  • <sub> — subscript, like the 2 in H2O.
  • <sup> — superscript, like the 2 in x2.
Tip: Formatting tags are for meaning, not decoration. If you only want a visual effect — for example, red text — use CSS instead.

Meaning first, looks second

HTML has two kinds of formatting tags. <strong> and <em> add meaning: this text is important, this word is stressed. Screen readers read them with emphasis, and search engines notice them. <b> and <i> only change the look — bold or italic — without adding any meaning. When in doubt, use <strong> and <em>.

Formatting tags

TagValueDescription
<b>textBold text, no extra meaning.
<strong>textImportant text — shown bold, with meaning.
<i>textItalic text, no extra meaning.
<em>textEmphasised text — shown italic, with meaning.
<small>textSmaller text, for side notes and fine print.
<mark>textHighlighted text, like a marker pen.
<del> / <ins>textDeleted text (struck through) / inserted text (underlined).
<sub> / <sup>textSubscript (H<sub>2</sub>O) / superscript (x<sup>2</sup>).

Here is how the two kinds differ in practice:

<p>This is <strong>very important</strong> news.</p>
<p>Water is H<sub>2</sub>O and x<sup>2</sup> means x squared.</p>
Note: Browsers show <strong> as bold and <em> as italic by default — but that is only the default look. Their real job is meaning, and CSS can change their appearance any time.
Tip: Use <mark> to highlight a search term or a key phrase in a long text. Readers spot it instantly, like a highlighter on paper.

Common mistakes

  • Using <b> for important text — use <strong> so screen readers stress it too.
  • Using <i> for emphasis — use <em> for the same reason.
  • Nesting formatting tags in the wrong order — close the inner tag first.
  • Formatting a whole paragraph bold instead of styling it with CSS.

Example explained

  • <p>This is <strong>important</strong> and this is <em>emphasised</em>.</p> — one paragraph shows both meaning tags: <strong> marks the word as important (shown bold), and <em> stresses the word (shown italic).
  • <small> shrinks the "Small print." text, and <mark> highlights "Highlighted text." like a yellow marker pen.
  • <del>₹500</del> strikes through the old price, and <ins>₹399</ins> underlines the new price — so the page shows both the change and the new value.
  • H<sub>2</sub>O drops the 2 below the line for the water formula, and 2<sup>2</sup> raises the 2 above the line for "2 squared".

Example

Example
<!DOCTYPE html>
<html>
<head>
<title>Formatting</title>
</head>
<body>

<p>This is <strong>important</strong> and this is <em>emphasised</em>.</p>
<p><small>Small print.</small> <mark>Highlighted text.</mark></p>
<p>Price was <del>₹500</del> <ins>₹399</ins>.</p>
<p>Water is H<sub>2</sub>O and 2<sup>2</sup> = 4.</p>

</body>
</html>

Output

Output — how it looks in the browser
Output of HTML Text Formatting Tags: bold, italic, mark & More

Try it yourself — live editor

Change the code below and press Run to see the result instantly. No file to save, no login needed.

Result

Frequently asked questions

The questions learners ask most about this lesson — read the question, then open it to see the answer.

1. What is the difference between strong and b?

Both look bold, but strong adds meaning: this text is important. Screen readers change their voice for strong, but not for b.

2. What is the difference between em and i?

Both look italic, but em adds meaning: stress this word when reading aloud. Screen readers stress em, but not i.

3. Which tag highlights text like a marker pen?

The mark tag. It highlights text, like a yellow marker pen, so readers spot a key phrase instantly.

Why learn this yourself — and not just ask AI?

AI can write code for you, but it cannot think for you. When you learn HTML yourself, your brain builds the real skill: you understand why a page looks the way it does, you can fix it when it breaks, and you can answer it in an exam or an interview without help. That is the skill that gets you a job — not a copied answer.

Get certified — just ₹10

Finish all 35 lessons, pass the test (80%), pay ₹10 and get your certificate.

Take the test

Prefer watching? Video courses teach the same topics step by step.

Go further with a full course

Free tutorials teach you the basics. Our paid courses add live projects, mentorship and a certificate.

AI Power Skills in 2 Days | Learn AI Text, Image, Video and Voice Tools
View
Website Design Using WordPress 3 Days (Basic to Advanced)
₹199
View
Full Stack PHP Development Course 2026
₹3,000
View
Browse all courses
HTML — Lessons
1. HTML Introduction: What is HTML? Learn with Examples 2. Best Free HTML Editors: Notepad to VS Code for Beginners 3. HTML Basic Structure: Doctype, Head, Body Explained 4. HTML Elements Explained: Tags, Content & Empty Elements 5. HTML Attributes List: href, src, alt, width, title & More 6. HTML Headings h1 to h6: Which Heading Tag to Use When 7. HTML Paragraphs: p Tag, br Line Breaks & pre Text 8. HTML Style Attribute: Colour, Font Size & Alignment 9. HTML Text Formatting Tags: bold, italic, mark & More 10. HTML Comments: How to Add Notes & Hide Code in HTML 11. HTML Colors: Names, HEX, RGB & HSL Colour Codes 12. HTML CSS: Inline, Internal & External Stylesheets 13. HTML Links: a Tag, href, New Tab & Email Links 14. HTML Images: img Tag, src, alt, Width & Formats 15. HTML Favicon: Create & Add a Browser Tab Icon 16. HTML Title Tag: How to Write a Good Page Title 17. HTML Tables: table, tr, th, td, colspan & rowspan 18. HTML Lists: ul, ol, dl & Nested Lists Explained 19. HTML Block vs Inline Elements: div, p, span Explained 20. HTML Div Tag: Group Content & Build Page Layouts 21. HTML Class Attribute: Style Many Elements at Once 22. HTML id Attribute: Unique IDs, Links, CSS & JavaScript 23. HTML Iframes: Embed YouTube, Maps & Pages in HTML 24. HTML JavaScript: script Tag, Clicks & First Example 25. HTML File Paths: Relative vs Absolute Paths Explained 26. HTML Head Element: title, meta, charset & viewport 27. HTML Layout: header, nav, main, footer Page Structure 28. HTML Responsive Design: Viewport, Images & Media Queries 29. Semantic HTML Tags: header, nav, main, article & footer 30. HTML Forms: input, label, select, checkbox & Submit 31. HTML Entities: & < > © with Examples 32. HTML Audio & Video Tags: controls, source & Fallback 33. HTML Accessibility: alt Text, Labels, Landmarks & ARIA 34. HTML Meta Tags & SEO: charset, viewport, OG Tags 35. HTML Quotations: blockquote, q, cite, abbr & address
Final Test — Certificate ₹10

🤖 KAMALDNP AI Assistant

Ask about courses, website & more

Hi! I'm KAMALDNP AI Assistant. Ask me about our courses, website features, or anything else! 😊
Please wait 5s...
🤖 KAMALDNP Assistant ✕

Request human callback:

🔐 Login Required
✕

Please log in to download. You will stay on this page after logging in!

New here? Register now →