Why can't sound travel through space?
The short answer
Sound is a wave of vibrating matter. Near-empty space has too few particles to carry that vibration.
How it works
In air, molecules pass the vibration to neighboring molecules. Sound also travels through water and metal, but its speed changes. Light can travel without matter.
A familiar example
Astronauts can talk inside a spacecraft because it contains air, but a direct shout cannot cross the vacuum outside.