Star formation begins in molecular clouds, dense regions of gas and dust in the interstellar medium. These clouds collapse under gravity, forming protostars that evolve into main sequence stars through various stages, including the T Tauri phase. Exoplanets, planets orbiting stars other than our Sun, form in protoplanetary disks around young stars. Scientists use methods like transit and radial velocity to detect these distant worlds, with notable discoveries including Earth-sized planets in habitable zones.