Snell's Law Calculator: Angle of Refraction and Total Internal Reflection
Snell's Law, published by Dutch mathematician Willebrord Snellius in 1621, describes how light changes direction when it crosses the boundary between two transparent media with different refractive indices. The law, n1 sin(theta1) = n2 sin(theta2), connects the angle of incidence in the first medium to the angle of refraction in the second. Both angles are measured from the normal (the perpendicular to the surface at the point of incidence). When light moves from a denser medium (higher n) into a less dense one (lower n), the refracted angle is larger than the incident angle. Beyond a threshold called the critical angle, no refraction occurs at all: the light undergoes total internal reflection and stays entirely within the denser medium. This principle is fundamental to fibre optic cables, camera lenses, corrective eyewear, gemstone cutting, and atmospheric optics such as rainbows and mirages. This calculator solves for the angle of refraction and critical angle using preset refractive indices for common materials, or your own custom values.
Angle of refraction: --
JavaScript is required for live calculations.
Snell's Law formula
n1 × sin(θ1) = n2 × sin(θ2)
Solving for the angle of refraction:
θ2 = arcsin(n1 × sin(θ1) / n2)
If the quantity (n1 sin(theta1) / n2) exceeds 1.0, total internal reflection occurs and no refracted ray exists.
Critical angle for total internal reflection
When n1 is greater than n2, total internal reflection is possible. The critical angle theta_c is the minimum angle of incidence at which TIR occurs:
θ_c = arcsin(n2 / n1) [only valid when n1 > n2]
Refractive indices of common materials
| Material | Refractive index (n) at 589 nm |
|---|---|
| Vacuum | 1.000 (exact) |
| Air (STP) | 1.000293 |
| Ice | 1.310 |
| Water (20 °C) | 1.333 |
| Fused silica glass | 1.458 |
| Crown glass | 1.520 |
| Flint glass | 1.620 |
| Diamond | 2.417 |
Note: refractive index varies with wavelength (dispersion). The values above are for sodium D light at 589 nm, the standard reference wavelength.
Frequently asked questions
What is Snell's Law?
Snell's Law (also called the Law of Refraction) states that when light crosses the boundary between two transparent media, the product of the refractive index and the sine of the angle (measured from the normal to the surface) is conserved: n1 sin(theta1) = n2 sin(theta2). Willebrord Snellius published this relationship in 1621. It explains why objects appear displaced when viewed through water and why lenses bend light to form images.
What is total internal reflection and when does it occur?
Total internal reflection (TIR) occurs when light travels from a denser medium (higher n) into a less dense medium (lower n) and the angle of incidence exceeds the critical angle. At and beyond the critical angle, no light is transmitted; all of it reflects back into the denser medium. The critical angle is theta_c = arcsin(n2/n1), valid only when n1 is greater than n2.
How does total internal reflection make fiber optics work?
Optical fibers consist of a glass or plastic core (high refractive index) surrounded by a cladding layer (lower refractive index). Light injected at shallow angles undergoes total internal reflection at the core/cladding boundary repeatedly along the fiber's length, travelling thousands of kilometres with very little loss. This is the physical basis for the entire global internet backbone and long-distance telephone networks.
Why does a rainbow appear at a specific angle in the sky?
Rainbows form because water droplets in the atmosphere refract (Snell's Law) and reflect sunlight. Different wavelengths (colours) of light have slightly different refractive indices in water, so they refract at slightly different angles (dispersion). The primary rainbow forms when light undergoes one internal reflection, with the combined refraction and reflection returning it to the observer at around 42 degrees for red and 40 degrees for violet light.
Why do diamonds sparkle so brilliantly?
Diamond has one of the highest refractive indices of any transparent material (approximately 2.42), giving it a critical angle of only about 24 degrees. Light entering a well-cut diamond frequently hits internal facets at angles greater than this critical angle, causing total internal reflection rather than transmission. The light bounces around inside before exiting through the top, producing the brilliant fire and scintillation that make diamonds prized as gemstones.