We propose that the Pipe Nebula is an HII region shell swept up by the B2 IV beta Cephei star theta Ophiuchi. After reviewing the morphological evidence by recent observations, we perform a series of analytical calculations. We use realistic HII region parameters derived with the radiative transfer code Cloudy from observed stellar parameters. We are able to show that the current size, mass and pressure of the region can be explained in this scenario. We investigate the configuration today and come to the conclusion that the Pipe Nebula can be best described by a three phase medium in pressure equilibrium. The pressure support is provided by the ionized gas and mediated by an atomic component to confine the cores at the observed current pressure. In the future, star formation in these cores is likely to be either triggered by feedback of the most massive, gravitationally bound cores as soon as they collapse or by the supernova explosion of theta Ophiuchi itself.