Index of Refraction Calculator
Convert between refractive index and the speed of light in a material, then trace a ray across the boundary with Snell's law.
🔍 What is the Index of Refraction?
The index of refraction, also called the refractive index, tells you how much a material slows down light. It is the ratio n = c / v of the speed of light in vacuum to the speed of light in the material. Vacuum has n = 1 by definition, air is just above 1, water is about 1.33, ordinary glass about 1.5 and diamond about 2.42. A larger index means slower light. The index has no unit, and for ordinary transparent materials it is never below 1. This calculator turns an index into a speed, or a speed into an index, and also gives the wavelength light takes on inside the material.
The index matters because it controls how light bends at a boundary. Snell's law, n1 sin θ1 = n2 sin θ2, links the angle of the incoming ray and the angle of the outgoing ray. That is the working principle of eyeglasses, camera lenses, microscopes, prisms and the optical fibers that carry internet traffic. When light goes from a dense material to a less dense one, there is a limit, the critical angle, beyond which no light escapes and the surface acts as a perfect mirror. Jewelers use the high index of diamond for sparkle, and swimmers see a pool as shallower than it is because of refraction.
Some points cause confusion. All angles in Snell's law are measured from the normal, which is the line perpendicular to the surface, and not from the surface. The frequency of the light does not change when it crosses a boundary, only the speed and the wavelength do. The index also depends a little on wavelength, which is why a prism separates white light into colors. And total internal reflection needs two conditions, not one: the light must be heading into a lower-index medium, and the angle must be beyond the critical angle.
The three modes cover the usual tasks. The first converts between n and v and lists common materials. The second solves Snell's law for the refraction angle, reports the critical angle and draws the rays. The third works backwards from two measured angles to identify an unknown material. For the speed of light itself, see the speed of light calculator, and for image formation by curved mirrors, the mirror equation calculator.
📐 Formula
📖 How to Use This Calculator
Steps
💡 Example Calculations
Example 1 — Speed of Light in Glass
Glass with n = 1.5, and green light of vacuum wavelength 589 nm
Example 2 — Index From a Measured Speed
Light travels at 2.25 × 108 m/s in a liquid
Example 3 — Air Into Glass
A ray in air (n = 1) hits glass (n = 1.5) at 30° from the normal
Example 4 — Total Internal Reflection in Glass
A ray inside glass (n = 1.5) meets the air boundary at 60°
Example 5 — Identify an Unknown Block
A ray from air at 45° refracts to 28.1° inside a transparent block
Example 6 — Water to Air
A ray in water (n = 1.333) reaches the surface at 40°
❓ Frequently Asked Questions
🔗 Related Calculators
What is the formula for the index of refraction?
The index of refraction is n = c / v, where c = 299,792,458 m/s is the speed of light in vacuum and v is the speed of light in the material. Glass with n = 1.5 slows light to 1.9986 x 10^8 m/s, two thirds of c.
How do you calculate the speed of light in a medium?
Divide the speed of light in vacuum by the refractive index: v = c / n. In water, n = 1.333 gives v = 2.249 x 10^8 m/s, about 75 percent of c.
What is Snell's law?
Snell's law states n1 sin(theta1) = n2 sin(theta2), where theta1 and theta2 are measured from the normal. Light entering glass (n = 1.5) from air at 30 degrees continues at 19.47 degrees, bending toward the normal.
What is the critical angle and how is it calculated?
The critical angle is the incidence angle in the denser medium at which the refracted ray runs along the surface. It is theta_c = arcsin(n2 / n1). For glass to air it is arcsin(1/1.5) = 41.81 degrees; for water to air it is 48.61 degrees.
When does total internal reflection occur?
It occurs when light goes from a higher index to a lower index and the angle of incidence is larger than the critical angle. Then sin(theta2) would be above 1, so no refracted ray exists and all the light is reflected. Optical fibers rely on this.
Does light bend toward or away from the normal?
Toward the normal when it enters a medium with a higher index, and away from the normal when it enters a medium with a lower index. If the indices are equal, it does not bend.
Can the index of refraction be less than 1?
For visible light in ordinary transparent materials it is 1 or more. Values slightly below 1 occur for X-rays, where the phase velocity can exceed c without breaking relativity. This calculator is for the ordinary case n of 1 or more.
What is the refractive index of water, glass and diamond?
Typical values near 589 nm are about 1.333 for water, 1.5 to 1.65 for glass depending on the type, and 2.417 for diamond. The materials table on this page lists several more with the speed of light in each.
Why does the wavelength change but not the frequency?
The frequency is fixed by the source, and it must be the same on both sides of the boundary. Since v = f lambda and v falls to c / n, the wavelength becomes lambda0 / n. Green light at 589 nm in vacuum has a wavelength of 392.7 nm in glass with n = 1.5.
How do you find the refractive index from two angles?
Rearrange Snell's law to n2 = n1 sin(theta1) / sin(theta2). A ray going from air at 45 degrees to 28.1 degrees in a block gives n2 = 1.5013, which is crown glass.
Does the angle of incidence of 0 degrees bend the light?
No. A ray along the normal has sin(theta1) = 0, so sin(theta2) = 0 as well and the ray goes straight through, although it still slows down or speeds up and part of it is reflected.