Because of its compatibility with semiconductor-based technologies, hafnia (HfO$_{2}$) is todays most promising ferroelectric material for applications in electronics. Yet, knowledge on the ferroic and electromechanical response properties of this all-important compound is still lacking. Interestingly, HfO$_2$ has recently been predicted to display a negative longitudinal piezoelectric effect, which sets it apart form classic ferroelectrics (e.g., perovskite oxides like PbTiO$_3$) and is reminiscent of the behavior of some organic compounds. The present work corroborates this behavior, by first-principles calculations and an experimental investigation of HfO$_2$ thin films using piezoresponse force microscopy. Further,the simulations show how the chemical coordination of the active oxygen atoms is responsible for the negative longitudinal piezoelectric effect. Building on these insights, it is predicted that, by controlling the environment of such active oxygens (e.g., by means of an epitaxial strain), it is possible to change the sign of the piezoelectric response of the material.