ScanSkill
CSS Examples

How to Add Space Between the Words using CSS

In this example, we will see how to add space between the words using CSS. We can use the word-spacing property to specify the spacing between the words.

Prerequisites

Example

HTML

<span class="example">mind the gap</span>

CSS

.example {
            word-spacing: 20px;
        }

Output

How to Add Space Between the Words using CSS

Here, we used word-spacing: 20px to add a space of 20px between the words.

Conclusion

In this example, we learned how to add space between the words using CSS. We used the word-spacing property to specify the spacing between the words.