Optical fibers use the principle of total internal reflection to carry light along their length. Light is kept in the core of the fiber by total internal reflection at the core-cladding interface. This occurs when the angle of incidence is greater than the critical angle, which depends on the refractive index difference between the core and cladding materials. Dispersion and attenuation are factors that limit the performance of optical fibers by causing signal degradation over long distances. Optical fibers have advantages over metal wires including higher bandwidth capacity, lighter weight, and immunity to electromagnetic interference.