Clear, practical technology insights BSOD Code Lookup · Windows Error Code Lookup · Wi-Fi Troubleshooting · PC Troubleshooting Checklist

How to Remove Spaces in Excel

Learn how to remove Spaces in Excel with clear steps, practical tips, and key considerations for completing the task safely and efficiently.

Table of Contents

This guide explains how to remove Spaces in Excel, with clear steps, practical tips, and important checks before you begin.

How to Remove Spaces in Excel screenshot

The article guides how to remove spaces in Excel, please follow along.

REMOVE WHITE BETWEEN THE WORDS

Use the TRIM function to remove spaces

The function of the TRIM function is to remove all spaces from a text, leaving only a space between words.

Syntax of the TRIM function: = TRIM (text)

For example, you need to remove spaces between words in the First and Last name column as below.

Use the TRIM function to remove spaces screenshot 2

First you need to create an extra column. Enter the formula in the first cell in the secondary column = TRIM (B7) with B7 being the cell to remove spaces.

Use the TRIM function to remove spaces screenshot 3

So you deleted the space between the words in the first cell, you copy the formula down to the next cells to remove the space of all columns.

Use the TRIM function to remove spaces screenshot 4

Now you can copy the sub column data to the main column by selecting the secondary column and pressing Ctrl + C to copy, then put the mouse in the first cell of the main column and right-click and select Value (V) in Paste Options.

Use the TRIM function to remove spaces screenshot 5

So you can delete the extra column.

Use the TRIM function to remove spaces screenshot 6

So using the TRIM function, you remove the spaces between words and leading spaces. But with big data, you use the TRIM function will be very time consuming.

Use Find & Replace

Using the search and replace feature ( Find & Replace ) will help you remove spaces between words faster, but leading spaces will still have a space that cannot be removed.

Step 1 : Select the data area to delete spaces, next you select Ctrl + H to open the Find & Replace dialog box .

Use Find & Replace screenshot 7

Step 2: In the Replace tab, press the spacebar twice in the Find what box, in the Replace With box press the space key once (searching for locations with two spaces will replace them with a space). Then click Replace All to replace all, a message appears, then click OK .

Use Find & Replace screenshot 8

Because there are many spaces with more spaces than the two spaces, click Replace All to replace, when the message We couldn't find anything to replace appears , click OK and turn off the Find & Replace dialog box. .

Use Find & Replace screenshot 9

So all spaces will be removed leaving only one space between words.

Use Find & Replace screenshot 10

DELETE WHITE PLACES BETWEEN NUMBERS

Use the Substitute function

The TRIM function helps you remove spaces between words and keep between words 1 space, but if you want to remove all spaces between numbers without any spaces, you need to use the SUBSTITUTE function.

You just need to use the SUBSTITUTE function formula to remove spaces.

= SUBSTITUTE (C7; ''; '')

Where C7 is the cell containing the number to delete all the spaces.

Use the Substitute function screenshot 11

Copying the formula to the remaining cells will delete all spaces between the numbers.

Use the Substitute function screenshot 12

Use Find & Replace

Step 1: In Excel worksheet, select the numeric data area to remove spaces, then press Ctrl + H to open the Find & Replace dialog box.

Use Find & Replace screenshot 13

Step 2 : In the Find & Replace dialog box, press the spacebar once in the Find What box and in the Replace with box you do not enter anything. Click Replace All to remove the space between numbers.

Use Find & Replace screenshot 14

If there are spaces in the middle of the numbers, then click Replace All again until no spaces are found, turn off Find & Replace . All spaces you select will have their spaces removed.

Use Find & Replace screenshot 15

Above are ways to help you can delete spaces between words, remove spaces between numbers in Excel. Hopefully the article will help you in working with Excel. Good luck!

FAQ

What should I know about Remove Spaces?

Focus on the key features, requirements, limitations, and practical use cases explained in this guide.

How do I get the best results with Remove Spaces?

Follow the recommended steps, use current software or information, confirm compatibility, and review settings before major changes.

Are there any risks or limitations?

Potential limitations depend on compatibility, data quality, cost, privacy, support, and how the product or method is used.

Discussion

Reader Comments 0

Sign in with email or Google to join the discussion.