To escape competition at the dung pile, a ball-rolling dung beetle forms a piece of dung into a ball and rolls it away. To ensure an their efficient escape from the dung pile, the beetles rely on a celestial compass to move along a straight paths. Here, we analyzed the reliability of different skylight cues for this compass and found that dung beetles rely not only on the sun, but also on the skylight polarization pattern. Moreover, we show the first evidence of an insect using the celestial light intensity gradient for orientation. Using a polarizer, we manipulated skylight so that the polarization pattern appeared to turn by 90°. The beetles then changed their bearing close to the expected 90°. This behavior was abolished if the sun was visible to the beetle, suggesting that polarized light is hierarchically subordinate to the sun. If the sky was depolarized and the sun was invisible, the beetles could still move along straight paths. We therefore analyzed the use of the celestial intensity gradient for orientation. Artificially rotating the intensity pattern by 180° caused beetles to orient in the opposite direction. The intensity cue was also found to be subordinate to the sun, and could play a role in disambiguating the polarization signal, especially at low sun elevations.