Answers.Body: <p>I've found that this happens when you end a line or string with a space and put nothing after it.</p>
  
  <p>"Text "<br> becomes "Text&nbsp;"</p>
  
  <p>If you then copy "Text " and paste it repeatedly you'd end up with "Text&nbsp;Text&nbsp;Text&nbsp;Text&nbsp;Text&nbsp;Text&nbsp;"</p>
  
  <p>Same for a lone space on a line.</p>
  
  <p>" "<br> becomes ";nbsp"</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-02-10T15:16:03.613Z
Answers.LastActivityDate: 2015-02-10T15:16:03.613Z
Answers.UserDisplayName: Andrew S
Answers.Body: <p>This is a bug in Redactor. There has been an <a href="https://craftcms.uservoice.com/forums/285224-bugs/suggestions/11027331-redactor-2-adds-extra-non-breaking-spaces" rel="nofollow noreferrer">ongoing bug report about it here</a>.
  But I found that if you use Firefox it doesn't add the non-breaking spaces when editing.</p>
  
  <p>onebrightlight (on Slack) suggested a temporary fix to replace them with spaces in your template code: </p>
  
  <pre><code>{{ entry.fieldname | replace({'&amp;nbsp;' : ''})|raw }}
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-09T10:51:36.923Z
Answers.LastActivityDate: 2017-02-09T10:51:36.923Z
Answers.UserDisplayName: Paul Frost
Body: <p>Is there any rhyme or reason to the adding of non-breaking spaces or traditional space? It seems to appear at random throughout the content in my rich text fields.</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2015-12-15T13:49:52.153Z
Comments.Text: Yep I'd like to know as well how to prevent Redactor adding those pesky `&nbsp;` all over the place. Seems the problem is worse with redactor 2.
Comments.UserDisplayName: Jérôme Coupé
Tags: <redactor><richtext>
Title: Rich text field adding &nbsp; and normal space char at random
ThreadText: # Rich text field adding &nbsp; and normal space char at random
  
  (Asked by: username_0 on 2014-12-11)
  
  Is there any rhyme or reason to the adding of non-breaking spaces or traditional space? It seems to appear at random throughout the content in my rich text fields.
  
  **Tags:** redactor, richtext
  
  > **Comments:**
  > **username_1**: Yep I'd like to know as well how to prevent Redactor adding those pesky `&nbsp;` all over the place. Seems the problem is worse with redactor 2.  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_2 on 2015-02-10. Score: 4
  
  I've found that this happens when you end a line or string with a space and put nothing after it.
  
  "Text "  
   becomes "Text "
  
  If you then copy "Text " and paste it repeatedly you'd end up with "Text Text Text Text Text Text "
  
  Same for a lone space on a line.
  
  " "  
   becomes ";nbsp"
  
  
  ---
  
  ### Answer by username_3 on 2017-02-09. Score: 1
  
  This is a bug in Redactor. There has been an [ongoing bug report about it here](https://craftcms.uservoice.com/forums/285224-bugs/suggestions/11027331-redactor-2-adds-extra-non-breaking-spaces).
  But I found that if you use Firefox it doesn't add the non-breaking spaces when editing.
  
  onebrightlight (on Slack) suggested a temporary fix to replace them with spaces in your template code:
  
  ```
  {{ entry.fieldname | replace({'&nbsp;' : ''})|raw }}
  
  ```
  
  
  ---
  
  