How can there be clouds in space?
© NASA/Robert Gendler
The correct designation for the Andromeda Nebula would be the Andromeda Galaxy because, in modern astronomy, the concept of cloud is used almost exclusively for concentrations of dust and gas found between the stars of a galaxy.
These concentrations of dust and gas emit light due to a variety of mechanisms. Emission nebulae shine because they are excited by the radiation of hot stars to emit light themselves. Reflection nebulae, on the other hand, reflect the light of nearby stars. Dark nebulae, also called dark clouds, are too distant from nearby stars to reflect their light or to be excited to emit light themselves. As dark clouds of gas and cosmic dust, they obstruct the light of stars and other shining nebulae lying behind them, and thus become visible to us. If the matter of a nebula gradually becomes denser, it turns into the birthplace of new stars.
German Aerospace Center