<p>I use <a href="http://xpath.alephzarro.com/" rel="noreferrer">XPather Browser</a> to check my XPATH expressions on an HTML page.</p>

<p>My end goal is to use these expressions in Selenium for the testing of my user interfaces.</p>

<p>I got an HTML file with a content similar to this:</p>

<pre>
&lt;tr&gt;
  &lt;td&gt;abc&lt;/td&gt;
  &lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/tr&gt;
</pre>

<p>I want to select a node with a text containing the string "<code>&amp;nbsp;</code>".</p>

<p>With a normal string like "abc" there is no problem.  I use an XPATH similar to <code>//td[text()="abc"]</code>.</p>

<p>When I try with an an XPATH like <code>//td[text()="&amp;nbsp;"]</code> it returns nothing.  Is there a special rule concerning texts with "<code>&amp;</code>" ?</p>

Search for
```
&nbsp;
```
or only
```
nbsp
```
- did you try this?