Select the text
Go to the Home tab
Click Replace
In Find what, type a space
In Replace with, leave it blank
Click Replace All
To remove extra spaces between words, press Ctrl+H
In Find what, type two spaces
In Replace with, type one space
Click Replace All
Repeat until no extra spaces remain
To remove paragraph spacing, select the text
Go to the Layout tab
Set Before to 0 pt
Set After to 0 pt
To remove line spacing, go to the Home tab
Click Line and Paragraph Spacing
Choose 1.0
To remove spaces at the start or end of a line, use Find and Replace
Search for leading spaces and replace them with nothing
Search for trailing spaces and replace them with nothing
