Planets are generally categorized into two main types: terrestrial planets and gas giants. Terrestrial planets, such as Earth and Mars, are composed mainly of rock and metal and have solid surfaces. Gas giants, like Jupiter and Saturn, are predominantly composed of hydrogen and helium and lack a solid surface.