How to Fix Random Lines That Print in Word Documents
Question details
The user needs to remove random lines that appear in Word documents, which also show up when exported to PDF or printed physically.

- Product
- Word
- Device & OS
- not provided
- Scenario
- Formatting a document for printing or PDF export where unexpected horizontal or vertical lines are disrupting the layout.
- Observed behavior
- Unwanted lines are visible within the document pages, and these artifacts persist in both the printed paper copies and generated PDF files.
Before modifying your document layout, print a completely blank document or a different file to confirm whether the random lines are caused by the specific document's formatting or a physical printer hardware issue.
Remove Unwanted Paragraph and Table Borders
Since the lines appear in PDFs and printouts, they are likely embedded in the document's formatting, most commonly as hidden paragraph borders.
Word often automatically applies paragraph borders when certain characters are typed repeatedly. These borders attach themselves to the paragraph and can look like random floating lines.
Click and drag to highlight the paragraphs or areas immediately above and below where the random line appears.
Navigate to the Home tab on the top ribbon menu and locate the Borders dropdown icon in the Paragraph group.
Click the dropdown arrow next to the Borders icon and select 'No Border'. The line should immediately disappear from the page.
If the line persists, double-click the header or footer area to see if a line was drawn there, or click on the line directly to see if it is a selectable shape or drawing object that can be deleted.

Copy Text to a New Blank Document
Use this method if the current document is corrupted and standard formatting tools cannot remove the persistent lines.
Update Office Software and Printer Drivers
If random lines appear in every single document you print, including entirely new ones, the issue may stem from software bugs or outdated printer communication.
Use WPS Writer to Clean Up Formatting and Print Seamlessly
WPS Office provides an intuitive, highly compatible word processing environment. It allows you to easily identify hidden borders, clear stubborn formatting artifacts, and export clean PDFs or printouts without unexpected lines.
- 1. Open the document in WPS Writer: Launch WPS Office and open the Word file containing the random lines.
- 2. Clear formatting: Highlight the affected area, navigate to the Home tab, and click the Eraser icon (Clear Formatting) to strip away hidden layout rules.
- 3. Remove borders manually: If the line remains, select the text, click the Borders dropdown in the Home tab, and choose 'No Border'.
- 4. Preview and print: Go to the Print menu or click 'Export to PDF' to confirm the document now looks exactly as intended.

Frequently Asked Questions
Why do random horizontal lines appear automatically when I type?
This is a feature called AutoFormat. When you type three hyphens (---), underscores (___), or asterisks (***) and press Enter, the software automatically converts them into a solid paragraph border. You can remove it by selecting the area and choosing 'No Border' from the formatting ribbon.
What if the lines only appear on the printed paper, but not on my screen or in PDFs?
If the lines are entirely absent from digital versions (like exported PDFs) but appear on paper, the issue is hardware-related. Your printer's toner might be leaking, the drum might be scratched, or the printheads require a cleaning cycle.
Can Track Changes cause random lines to print?
Yes. If Track Changes is enabled, vertical lines often appear in the left margin to indicate where edits were made. To prevent these from printing, go to the Review tab and change the display setting from 'All Markup' to 'No Markup' before printing.
How do I delete a line that I can click and drag?
If you can click on the line and it shows selection handles (small circles or squares at the ends), it is a Drawing Shape rather than a formatting border. Simply click the line to select it and press the Delete or Backspace key on your keyboard.




