Microsoft Word possesses a highly aggressive “AutoFormat As You Type” engine. One of its most notorious features is automatic border creation. If you are typing a document and you enter three hyphens (---) or three underscores (___) and then press the Enter key, Word instantly transforms those characters into a solid, edge-to-edge horizontal black line (a border) across your page.
While this is a fast way to visually separate sections of a document, it is an absolute nightmare if you are trying to write plain text, write markdown documentation, or format a script. Worse, because Word technically inserts this line as a “Paragraph Border” rather than an actual character, it is incredibly difficult to delete—pressing the Backspace key often does absolutely nothing.
You can turn off this specific formatting rule to prevent Word from hijacking your hyphens.
How to Turn Off Automatic Border Lines
This rule is buried within the AutoCorrect exceptions menu.
- Open your document in Microsoft Word.
- Click on File in the top-left corner of the ribbon.
- Click on Options at the bottom of the left sidebar.
- In the Word Options window, select Proofing from the left-hand navigation pane.
- Click the AutoCorrect Options… button in the main pane.
- A new dialog box will open. Click on the tab labeled AutoFormat As You Type.
- Look under the “Apply as you type” section.
- Uncheck the box labeled Border lines.
- Click OK twice to close both windows and save your changes.
Microsoft Word will immediately respect your keystrokes. You can now type three hyphens (---) and press Enter, and the characters will simply remain as three hyphens on a new line, without generating a massive black border.