---
title: "Are white space characters used for spacing?"
date: "2024-10-25T09:27:48+00:00"
summary: "Discover how to properly control spacing within words for better accessibility and user experience in web content."
image:
type: "page"
url: "/web-governance/are-white-space-characters-used-spacing"
id: "783e712f-69c9-43a7-b992-a0e16fcc471e"
---

Table of contents will be added

1.3.2 Meaningful Sequence

Introduction
------------

This document provides information about the Acquia Web Governance accessibility check:

*   Are white space characters used for spacing?

What
----

White space characters such as spaces, tabs, line breaks, or carriage returns must not be used to visually format individual words. 

Why
---

White space characters like spaces, tabs, line breaks, or carriage returns that are used to visually format individual words can harm accessibility. This practice can create challenges for users who rely on screen readers or other assistive technologies, as these tools interpret white space differently than visual users. Instead of seeing a well-formatted word, users may hear unnatural pauses or broken speech, which makes the content hard to understand. Additionally, this method can cause layout issues on different devices.

Who
---

### Affected users

This check affects the following users who have:

*   Visual impairments: Who access the site contents with a screen reader or screen magnification software.
    
    #### User story
    
    ![Woman smiling while doing yoga, with a child playfully climbing on her back in a cozy living room.](https://acquia.widen.net/content/ab902dae-f391-4c4d-a431-77ca08d2adc6/web/Mon_AccessibilityHelpCenter-UserStory-WomanDoingYogaWithGirl.png)
    
    Bridgit is a blind mother to a five-year-old girl and an 11-year-old boy:
    
    _"Sometimes it feels like my screen reader gets the hiccups. It is kinda funny, but you know, when they format headings or other text with spaces between the letters to make it look nice for people who can see, it messes things up for me. Instead of reading the words, it is like my screen reader just starts hiccuping out the letters one by one, really fast. I have to concentrate so hard, and it is like I am listening to someone with the worst case of the hiccups!”_
    

Examples
--------

This section provides some examples of the issue.

### Example: Heading formatted with the space character

In the example, a song title is formatted with spaces between each letter. This means that screen readers, which are often used by people who are blind, will not read the title as words but as a sequence of letters in quick succession. This makes it difficult to understand the meaning.

    <h1>B a c k  I n  B l a c k</h1>
    <p>Back in black, I hit the sack</p>
    <p>I've been too long, I'm glad to be back</p>
    <p>Yes, I'm let loose from the noose</p>

### Example: Heading formatted with CSS

In the example, a visual effect of spacing between the letters is achieved once again. However, because this effect is created with CSS `letter-spacing`, it does not interfere with the correct reading by screen readers.

    <h1 style="letter-spacing: 1em;">Back in Black</h1>
    <p>Back in black, I hit the sack</p>
    <p>I've been too long, I'm glad to be back</p>
    <p>Yes, I'm let loose from the noose</p>

How
---

This section provides information about how to identify and fix the issue.

#### How to identify it

The Acquia Web Governance platform highlights elements that contain text nodes that are formatted with whitespace characters. 

#### How to fix it

To resolve this issue, adjust your content to avoid whitespace characters for visual formatting. Instead, use CSS as illustrated in the _Examples_ section above.

Additional resources
--------------------

### WCAG success criteria

[1.3.2 Meaningful Sequence](https://www.w3.org/WAI/WCAG22/Understanding/meaningful-sequence.html)