Niemi made nine saves in the third period to help the Sharks hang on for their fifth win in six games.
Patrick Elias got the Devils' only goal on a third-period power play.
Martin Brodeur made 28 saves for New Jersey, which wrapped up a three-game California road trip with a 2-1-0 mark.
LGBT community has 'bullied the American people': Bachmann
Astronomers offer more expansive view of universe