Rainbows are formed when sunlight is refracted, or bent, and then reflected inside raindrops, separating the sunlight into its various colors. This process is called dispersion. The sunlight enters a raindrop, is refracted, reflects off the inside surface of the drop, and is refracted again as it exits the drop, creating the beautiful arc of colors we see as a rainbow.