🔤 CSS Lesson 4 - Fonts & Text

Learn how to make text beautiful and easy to read.

Changing Font Size

h1{

font-size:40px;

}

Changing Font Family

body{

font-family:Arial,sans-serif;

}

Making Text Bold

p{

font-weight:bold;

}

💻 Try It Yourself

Open the playground and create:

🚀 Open Playground

More Text Properties

Property Example
text-align center
text-transform uppercase
letter-spacing 2px
line-height 1.8
text-shadow 2px 2px 5px gray
âš  Pro Advice: Don't use too many different fonts. Two fonts are usually enough for a professional website.

🧠 Quick Quiz

Which property changes text size?

⬅ Previous Next Lesson ➜