Jupiter
Jupiter and other gas giants probably started as rocky planets, similar to Earth. This theory is called the core accretion model. The rocky core would have formed in the early Solar System, within a disk of gases around the Sun. When the planet reached a critical mass, its gravity started to quickly capture lots of gas. In this way, Jupiter became a giant planet. In order for Jupiter to reach this critical mass before the gas disk disappeared, there must have been lots of ice in the area. Jupiter must have formed outside the snow line, the area that is cold enough for water to freeze.