Snell's Law Calculator: Refraction Angle, Refractive Index and Critical Angle
Enter the refractive indices of two media and an angle to apply Snell's law. Choose what to solve for, pick a material from the preset list or enter a custom index, and get the refraction angle, critical angle, speed ratio, and wavelength ratio with full step-by-step working shown.
Formula
Worked example
Light travels from air (n1 = 1.000) into water (n2 = 1.333) at 30 degrees: sin(theta2) = (1.000 x sin 30 degrees) / 1.333 = 0.500 / 1.333 = 0.3751, so theta2 = arcsin(0.3751) = 22.08 degrees. The ray bends toward the normal because water is optically denser than air.
What is Snell's law?
Snell's law (also called the law of refraction) describes how a ray of light changes direction when it crosses the boundary between two transparent media with different optical densities. It was formulated independently by Willebrord Snellius (1621) and Rene Descartes (1637). The law states that the product of the refractive index and the sine of the angle of incidence in one medium equals the same product in the other medium: n1 sin(theta1) = n2 sin(theta2). The angles are always measured from the normal - the imaginary line perpendicular to the boundary at the point of contact, not from the boundary surface itself.
How to use this calculator
Choose what you want to solve for in the top dropdown: angle of refraction (the default), angle of incidence, n1 (refractive index of the first medium), or n2 (refractive index of the second medium). Select a material preset for each medium to auto-fill its refractive index, or choose Custom and type your own value. Enter the known angle or angles, and the calculator returns the missing quantity plus the critical angle (when n1 > n2), the speed ratio, the wavelength ratio, and a chart showing how the refraction angle varies across all possible incident angles for the current pair of media.
Critical angle and total internal reflection
When light travels from a denser medium (higher n) to a less dense medium (lower n), there exists a critical angle above which no refracted ray can form. At exactly the critical angle, the refracted ray travels along the boundary (theta2 = 90 degrees); beyond it, the ray is completely reflected back into the first medium - a phenomenon called total internal reflection (TIR). The critical angle formula is theta_c = arcsin(n2 / n1), valid only when n1 > n2. TIR is the operating principle behind optical fibres: light launched within a glass or plastic core is repeatedly reflected at the core-cladding boundary and confined over kilometres without escaping. Diamonds are cut to exploit TIR: the gem is shaped so that most light that enters undergoes multiple internal reflections before exiting from the top facets, producing the characteristic brilliance.
Speed ratio, wavelength ratio and the refractive index
The refractive index of a medium is defined as n = c / v, where c is the speed of light in vacuum (299,792 km/s) and v is the phase speed of light in the medium. A higher n means light travels more slowly and bends more strongly. When light crosses a boundary, its frequency stays the same but its speed and wavelength both change in proportion: v2 / v1 = lambda2 / lambda1 = n1 / n2. A ray entering water from air slows to about 225,000 km/s and its wavelength shrinks by the same factor. This speed change is the physical cause of refraction: different parts of a wavefront reach the boundary at slightly different times, so the wavefront pivots toward (or away from) the normal.
Applications of refraction and common examples
Refraction shapes everyday life in dozens of ways. A straw in a glass of water appears bent at the surface because light from below the waterline changes direction as it enters air. Camera and microscope lenses stack multiple refracting surfaces to focus light precisely. The human eye refracts light through the cornea and lens onto the retina; glasses and contact lenses correct for over- or under-refraction. Atmospheric refraction bends starlight and sunlight, making stars appear slightly higher in the sky than they truly are and producing mirages on hot roads. Optical fibres carry internet traffic by trapping pulses of light through total internal reflection in a glass core as thin as a human hair.
Refractive indices of common materials (at 589 nm, 20 degrees C)
| Material | Refractive index (n) | Speed of light (km/s) |
|---|---|---|
| Vacuum | 1.0000 | 299,792 |
| Air | 1.0003 | 299,702 |
| Ice | 1.310 | 228,849 |
| Water (20 degrees C) | 1.333 | 224,900 |
| Ethanol | 1.361 | 220,274 |
| Acrylic (PMMA) | 1.490 | 201,207 |
| Crown glass | 1.520 | 197,232 |
| Flint glass | 1.620 | 185,057 |
| Sapphire | 1.770 | 169,374 |
| Diamond | 2.417 | 124,042 |
The refractive index n = c / v, where c is the speed of light in vacuum and v is the speed in the medium.
Frequently asked questions
What is Snell's law used for?
Snell's law is used to predict how much a ray of light (or any other wave) bends when it passes from one transparent medium into another. It underpins the design of lenses, prisms, optical fibres, microscopes, cameras, eyeglasses, and most optical instruments. It also explains everyday phenomena such as a stick appearing bent in water, atmospheric mirages, and the rainbow.
How do you calculate the angle of refraction?
Rearrange Snell's law to isolate theta2: sin(theta2) = (n1 / n2) x sin(theta1). Then take the inverse sine (arcsin) of the result. For example, if light passes from air (n1 = 1.000) into crown glass (n2 = 1.520) at 45 degrees, sin(theta2) = (1.000 / 1.520) x sin(45 degrees) = 0.4654, so theta2 = arcsin(0.4654) = 27.7 degrees.
What is the critical angle?
The critical angle is the minimum angle of incidence, measured from the normal, at which total internal reflection occurs. It only exists when light travels from a denser medium to a less dense medium (n1 > n2). The formula is theta_c = arcsin(n2 / n1). For a glass-to-air boundary (n1 = 1.52, n2 = 1.00), the critical angle is arcsin(1.00 / 1.52) = 41.1 degrees. Any incident angle above 41.1 degrees causes complete reflection with no transmitted ray.
What is total internal reflection?
Total internal reflection (TIR) occurs when a ray in a denser medium strikes the boundary to a less dense medium at an angle greater than the critical angle. Instead of partially refracting into the second medium, 100% of the light is reflected back into the first medium. This is how optical fibres work: light bounces repeatedly along the inside of a thin glass or plastic core with virtually no loss at each reflection, allowing signals to travel across oceans.
Does Snell's law apply to waves other than light?
Yes. Snell's law applies to any wave that changes speed at a boundary: sound waves refract when they pass from air into water or between air masses of different temperatures (explaining why sound seems louder at night), seismic waves refract as they travel through layers of the Earth, and radio waves refract in the ionosphere. The same formula n1 sin(theta1) = n2 sin(theta2) holds when n1 / n2 is replaced by v1 / v2, the ratio of wave speeds in the two media.
Why does a straw look bent in a glass of water?
Light leaving the submerged part of the straw bends away from the normal as it crosses from water (n = 1.333) to air (n = 1.000). Your eyes trace straight lines backward from the incoming rays, placing the apparent image of the straw at a different position than the real straw. The part of the straw in air and the apparent position of the part in water no longer line up, making the straw look kinked at the water surface.
How does the refractive index relate to the speed of light?
The refractive index n of a medium is the ratio of the speed of light in vacuum (c = 299,792 km/s) to the phase speed of light in that medium (v): n = c / v. A medium with n = 1.5 slows light to c / 1.5 = 199,861 km/s. Higher n means slower light and stronger bending when a ray crosses a boundary.
Can I use Snell's law to find the refractive index of an unknown material?
Yes. If you know the refractive index of one medium and can measure both angles, you can rearrange Snell's law to n2 = n1 sin(theta1) / sin(theta2). This is the basis of refractometry: gemologists, chemists, and food scientists use an instrument called a refractometer to identify unknown liquids or solids by measuring how strongly they bend light. This calculator supports that reverse-solve directly in the 'Solve for n2' mode.