Whitespace is any part of text which doesn't contain a visible character. It generally acts normally as you would expect on FANDOM, but there are some situations where whitespace acts counter-intuitively, especially if entered using the classic editor or source mode. This page lists some of those situations, and how to avoid them.
To get a line break to display on the page, two line breaks (or two presses of the enter/return key on your keyboard) are needed. If you only use one line break, the text after the line break will just continue on next to the text above it as if separated by a normal space character. For example:
However, single line breaks don't follow this pattern when part of a list of either ordered or unordered type. For example, using an unordered list:
*Item 1 *Item 2 List ended.
will display as:
- Item 1
- Item 2
This specific problem is often encountered when a single line space is used inside a template for information layout in the source code, causing some templates to force a line break when used inside a list.
Whitespace at the beginning of lines
If a space is added at the beginning of a line or paragraph, all the following text will be placed inside a one line high box. For example:
Hello world! Did you know that you can learn more about links at [[Help:Link]]?
Hello world! Did you know that you can learn more about links at Help:Link?
This box is similar to the box formed by pre tags, however, unlike the pre tags, it does parse wikitext.
Multiple spaces in a row
If you intend to separate text with multiple spaces, all those spaces will be condensed down to one single space instead of giving the desired spacing. For example:
This can be avoided by using what is known as a non-breaking space which doesn't collapse when a page is displayed to the reader. This is produced by typing . For example:
Note that this is only the case for normal space characters. Line breaks won't collapse on themselves with the exception of when a single line break is used, as documented above.
Whitespace and non-breaking space characters should be avoided for adding indention to a block of text. The wikitext equivalent, a colon at the beginning of a newline, should be used instead. The level of indentation can be changed using the number of colons placed:
This is a line of text. :This is an indented line of text. ::This line of text is more indented.
This is a line of text.
- This is an indented line of text.
- This line of text is more indented.
Note that if you're indenting the text, the normal line-break collapsing rules don't apply and you can put a line of different indentation directly under another line.
Further help and feedback
- Browse and search other help pages at Help:Contents
- Check Fandom Community Central for sources of further help and support
- Check Contacting Fandom for how to report any errors or unclear steps in this article
- Learn how to use Fandom in Fandom University: short how-to videos for all levels of experience