How to replace multiple white spaces with one white space December 26, 2022 by Tarik string cleanedString = System.Text.RegularExpressions.Regex.Replace(dirtyString,@"\s+"," ");