The Crescent Nebula is formed by the fast moving solar wind hitting the shell of gas ejected from the central star when it went through its red giant phase. The solar wind strikes the gas and creates a shockwave, causing the gas to glow as an emission nebula.