The atmosphere on the red planet is very different from Earth’s and the light from the Sun scatters based on what’s in the atmosphere.
The martian atmosphere is very thin – its pressure is equivalent to about 1 percent of Earth’s. It is made of mostly carbon dioxide and has a lot of dust.
The fine dust that permeates the thin atmosphere on Mars is the right size so that blue light comes through more efficiently than longer-wavelength colors of light like red. So when the light of other colors shines through the atmosphere, blue light stays closer to the direction of the Sun.
If it weren’t for the dust in Mars’s sky, however, the sky would be nearly black. Because sunlight has to go through a much thicker atmosphere when the Sun is on the horizon the blue effect is more pronounced at sunrise or sunset than during the middle of the day.
On Earth, it is the other way around. The molecules that make up our atmosphere also partially block the sunlight. Blue light bounces off air molecules giving our sky its characteristic hue.