Nilstorp, a 29-year-old veteran of the Swedish Elite League, notched his first NHL win in his fourth North American start as Dallas snapped a two-game losing streak.
Antti Niemi coughed up three goals on 28 shots for the Sharks, who completed a 1-4-1 road trip.
Patrick Marleau got San Jose's only score.
Senate Democrats to pull all-nighter on climate change
Interpol investigating stolen passports on missing flight