Stars are formed when gravity pulls together clouds of gas and dust in deep space. As more gas and dust get pulls in, the clump heats up. Finally, heat and pressure cause the gases to undergo a reaction called nuclear fusion. Some stars seem brighter than others. The brightness of a star is called its magnitude, or size.
Big stars are brighter than little stars, and so have greater absolute magnitude.
Stars close to Earth also appear brighter than those farther away. They have greater apparent magnitude. Our sun appears to be the brightest star to us because it is the closest to Earth. Stars have different colors, depending on how hot they are. Very hot stars are blue, and the coolest stars are red.