In almost any tool, context, or mode, pressing will deselect the current selection. If you have a subselection, typically pressing once will deselect the subselection and the second will deselect the regular selection.
Another way to deselect is by clicking the empty canvas (or a locked object with nothing underneath it). This, however, works only in Selector and in those tools where a simple click selects objects (5.5 Selecting by Clicking: Other Tools). In complex drawings where accessing empty canvas may be difficult, is by far the most convenient way to deselect.
Also, by default Inkscape deselects when you switch the current layer (see 4.6 Layers). This can be disabled on the Selecting tab of the Inkscape Preferences dialog.