Opals are formed through a natural process involving water, silica, and cavities in the Earth's crust.