Tobias Weis gave Hoffenheim the lead after 11 minutes and Sejad Salihovic doubled the advantage eight minutes later.
Timmy Simons pulled a goal back for Nuremberg in the 58th minute from the spot.
Hoffenheim had collected just one victory in their last five matches but improved to 27 points - three points from the relegation play-off.
Nuremberg remained on 38 points after their third straight loss.
Hoffenheim had a strong start to the match with Fabian Johnson forcing Nuremberg goalkeeper Raphael Schafer into a fine save in the first minute and then Roberto Firmino shot just wide a minute later.
The hosts continued the push forward and grabbed the lead in the 11th minute with Johnson crossing to Weis, who slotted home into an empty goal.
Hoffenheim doubled the advantage after 19 minutes with Kevin Volland crossing to the far left post where Salihovic headed into the far right corner.
Salihovic had a goal disallowed in the 48th minute as his free-kick was chalked off due to a foul.
The visitors went close again four minutes later but Schafer made a great save from Weis' volley 11 yards out.
Nuremberg pulled a goal back in the 58th minute from the penalty spot as Simons went straight down the middle after Hoffenheim keeper Koen Casteels had fouled Niklas Stark in the box.
The visitors nearly equalised three minutes later but Sebastian Polter shot wide.
Hoffenheim were close to making it 3-1 after 79 minutes but Schafer saved Joselu's attempt.