Many organic molecules, including food dyes, are colored because they contain chromophores. A chromophore is a region in the molecule where the energy difference between two different molecular orbitals falls within the range of the visible spectrum. Light that hits the molecule can thus excite the electrons in the chromophore, resulting in the emittance of a particular wavelength of light.
$\hspace{1cm}$
In urobilin (seen above) specifically, the tetrapyrrole moiety, as a result of its conjugated pi-bond system, is the chromophore that gives this compound its characteristic yellow color.