* NaNO2 is formed from the reaction of a strong base (NaOH) and a weak acid (HNO2).
* Strong bases completely dissociate in water, releasing hydroxide ions (OH-)
* Weak acids only partially dissociate in water.
* The resulting salt (NaNO2) will hydrolyze in water, meaning the nitrite ion (NO2-) will react with water to produce a small amount of hydroxide ions (OH-), making the solution slightly basic.
In summary: The presence of the conjugate base of a weak acid (NO2-) in the salt leads to the production of hydroxide ions, resulting in a basic solution.