Ludovit Reis' awkward floating cross went into the net off the far post after 57 minutes to give Hamburg a slim advantage ahead of Monday's return leg.
- Don't have ESPN? Get instant access
Hamburg finished third in the second division with Schalke 04 and Werder Bremen winning automatic promotion.
Hertha, coached by Hamburg great Felix Magath, had the ball in the net on the stroke of halftime only for the effort to be ruled offside.
They struggled to bounce back from going behind as Hamburg controlled the pace and shut down spaces quickly.
Hertha, facing a seventh relegation, finished 16th after the last Bundesliga matchday to go into the playoff. Greuther Fuerth and Arminia Bielefeld were relegated from the top division.