No, the sun is white in space. This is because it emits a constant heat and light that travels through hundreds of light years to reach the earth. The sun emits all lights of the spectrum. This is why it is able to create the rainbow when it passes through a different refractive medium.
When observed in space it shows off as a ball of whit light shining brightly. The light rays have all the visible spectrum as well as the non-visible parts of the spectrum. In space, all of these lights reach unhindered. On earth, many of these harmful rays are filtered out by the ozone layers.