/

Refractive Index Calculator — Snell’s Law, Angle of Refraction & Critical Angle

Refractive Index Calculator — Snell's Law, Angle of Refraction & Critical Angle
Optics Tool

Refractive Index Calculator

Calculates the angle of refraction using Snell's law (n₁sinθ₁=n₂sinθ₂), finds the refractive index from speed or wavelength measurements, and determines the critical angle for total internal reflection — with full step-by-step working and a real-time ray diagram updating as you type.

⚡ Snell's Law — Law of Refraction

n₁ × sin(θ₁) = n₂ × sin(θ₂)

All angles measured from the normal (perpendicular to interface) — NOT from the surface itself

Refractive Index Calculator — Snell's Law · Critical Angle · Ray Diagram
n₁ =
°
n₂ =
Air→Water 30°
Air→Glass 45°
Water→Air 30°
Air→Diamond 45°
Glass→Air 50° (TIR)
Find n₂: 30°→19.47°

Total internal reflection occurs when light travels from denser → less dense medium (n₁ > n₂) and the angle of incidence exceeds the critical angle θc = arcsin(n₂/n₁).

n₁ =
n₂ =
Glass→Air (optical fiber)
Diamond→Air
Water→Air
Glass→Water

The refractive index n = c/v, where c = 2.99792458×10⁸ m/s (speed of light in vacuum) and v is the speed of light in the material.

Water: 2.249×10⁸
Glass: 1.972×10⁸
Diamond: 1.24×10⁸
Vacuum: c

All refractive indices at 589 nm (sodium D-line), standard reference temperature. Click any row to load that material into Snell's Law calculator.

Gases (STP, 589 nm)
MaterialnNotes
Vacuum1.00000Exact — by definition
Air (STP)1.00029Standard temperature & pressure
Air (room temp)1.00027~20°C, 1 atm
Carbon dioxide1.00045STP
Liquids (589 nm, 20°C)
MaterialnNotes
Water (20°C)1.3330Most common liquid
Water (0°C)1.3340Near freezing
Ethanol1.3610Alcohol
Glycerin1.4730High viscosity
Olive oil1.4670Vegetable oil
Benzene1.5011Aromatic hydrocarbon
Carbon disulfide1.6280High-dispersion solvent
Carbon tetrachloride1.4610
Glasses (589 nm)
MaterialnNotes
Crown glass1.5200Common optical glass
Flint glass1.6200High-dispersion glass
Borosilicate glass1.4740Pyrex/lab glass
Fused silica (quartz)1.4584UV-transparent
Crystals & Minerals
MaterialnNotes
Diamond2.4170Highest natural n; θc=24.4°
Sapphire1.7620Al₂O₃
Cubic zirconia2.1500Diamond simulant
Ice1.3090H₂O solid
Rock salt (NaCl)1.5440
Calcite (ordinary)1.6580Birefringent
Fluorite (CaF₂)1.4340UV optics
Rutile (TiO₂)2.9070Very high n
Plastics / Polymers
MaterialnNotes
Acrylic / PMMA / Lucite1.4910Plexiglass
Polycarbonate1.5860Safety lenses
Polystyrene1.5900
Polyethylene1.5000
Semiconductors
MaterialnNotes
Silicon3.9600Infrared optics
Germanium4.0000IR lenses
Gallium arsenide3.6000Laser diodes
Human Eye
ComponentnNotes
Cornea1.3760Main refracting surface
Crystalline lens1.3860Average; gradient structure
Vitreous humor1.3360Gel-like interior
Error
Ray Diagram — Real-Time (Snell's Law)
Step-by-Step Working

Snell's Law — The Angle of Refraction Formula

This refractive index calculator solves Snell's law (n₁sinθ₁=n₂sinθ₂) for any unknown variable — angle of refraction, angle of incidence, or either refractive index — and determines the critical angle for total internal reflection, with real-time ray diagram.

Snell's law describes how light bends when crossing the boundary between two media with different refractive indices:

n₁ × sin(θ₁) = n₂ × sin(θ₂) n₁, n₂ = refractive indices | θ₁ = angle of incidence | θ₂ = angle of refraction — ALL from the NORMAL

Critical rule for the angle of refraction formula: ALL angles in Snell's law — both θ₁ and θ₂ — are measured from the normal (the line perpendicular to the interface), NOT from the surface itself. This is the most common source of errors in refraction problems.

Solving for the angle of refraction: θ₂ = arcsin(n₁ × sinθ₁ / n₂). When light enters a denser medium (n increases), the angle decreases — light bends toward the normal. When entering a less dense medium, the angle increases — light bends away from the normal.

Memory aid for Snell's law: "Dense medium = small angle." Entering a material where light slows down (higher n) means the ray compresses toward the normal. The Snell law equation n₁sinθ₁=n₂sinθ₂ enforces this — if n₂ > n₁, then sinθ₂ < sinθ₁, so θ₂ < θ₁.

How to Calculate the Angle of Refraction — Step-by-Step

Four-step method to find the angle of refraction using the angle of refraction formula:

  1. Identify n₁, n₂, and θ₁ — find refractive indices from tables; measure θ₁ from the normal (not the surface)
  2. Compute n₁×sinθ₁ — this product is conserved across the interface (Snell's invariant)
  3. Divide by n₂ to get sin(θ₂): sin(θ₂) = n₁sinθ₁/n₂
  4. Apply arcsin to find θ₂. If sin(θ₂) > 1: total internal reflection occurs, no refracted ray exists

Example 1 — Air → Water: θ₁ = 30°

  1. n₁ = 1.000 (air), n₂ = 1.333 (water), θ₁ = 30°
  2. n₁sinθ₁ = 1.000 × sin(30°) = 1.000 × 0.5000 = 0.5000
  3. sin(θ₂) = 0.5000 / 1.333 = 0.37509
  4. θ₂ = arcsin(0.37509) = 22.03° (bends toward normal — entering denser medium)

Example 2 — Air → Diamond: θ₁ = 45°

  1. n₁ = 1.000, n₂ = 2.417, θ₁ = 45°
  2. sin(θ₂) = 1.000 × sin(45°) / 2.417 = 0.7071/2.417 = 0.29256
  3. θ₂ = arcsin(0.29256) = 17.00° — dramatic bending toward normal

Example 3 — Water → Air: θ₁ = 40° (bends away)

  1. n₁ = 1.333, n₂ = 1.000, θ₁ = 40°
  2. sin(θ₂) = 1.333 × sin(40°) / 1.000 = 1.333 × 0.6428 = 0.8568
  3. θ₂ = arcsin(0.8568) = 58.98° — bends away from normal (entering less dense medium)

Example 4 — Find n of Unknown Material: θ₁=45°, θ₂=28°

  1. n₁ = 1.000 (air), θ₁ = 45°, θ₂ = 28°
  2. n₂ = n₁sinθ₁/sinθ₂ = 1.000 × sin(45°)/sin(28°) = 0.7071/0.4695 = 1.506
  3. Likely material: Flint glass (n=1.52) or similar glass

Example 5 — Glass→Air, Check if TIR: θ₁=50°

  1. n₁=1.52, n₂=1.00, critical angle = arcsin(1/1.52) = 41.14°
  2. Since 50° > 41.14° → Total Internal Reflection occurs
  3. sin(θ₂) = 1.52×sin(50°)/1.00 = 1.164 > 1 → no refracted ray

What Is Refractive Index? — Definition and Physical Meaning

The refractive index n of a medium is defined as the ratio of the speed of light in vacuum to the speed of light in the medium:

n = c / v    also    n = λ_vacuum / λ_medium c = 2.99792458×10⁸ m/s | v = speed in medium | n always ≥ 1 for ordinary materials

Physical meaning: n = 1.5 means light travels at c/1.5 = 2/3 the speed of light in that material. Water (n=1.333): v = c/1.333 = 2.249×10⁸ m/s. Diamond (n=2.417): v = c/2.417 = 1.240×10⁸ m/s — barely over 40% of c.

Why does light slow down? When light enters a medium, it interacts with the electrons in the material — being absorbed and re-emitted repeatedly. This absorption-re-emission cycle causes an effectively slower propagation speed, encoded in the refractive index.

The refractive index also equals λ_vacuum/λ_medium — the wavelength shortens inside the medium by a factor of n, but the frequency stays constant. This is why the angle of refraction formula involves n: the change in wavelength causes the wavefronts to tilt, producing the observed bending at the interface.

Critical Angle and Total Internal Reflection

Total internal reflection (TIR) is a phenomenon that occurs under two simultaneous conditions: (1) light must be traveling from a denser medium (higher refractive index) to a less dense medium, AND (2) the angle of incidence must exceed the critical angle.

θc = arcsin(n₂ / n₁)    [requires n₁ > n₂] At θ₁ = θc: refracted ray travels along interface (θ₂=90°) | At θ₁ > θc: total internal reflection

Derivation from Snell's law: at the critical angle, θ₂ = 90°, so sin(θ₂) = 1. Then n₁sinθc = n₂×1 → sinθc = n₂/n₁ → θc = arcsin(n₂/n₁).

  • Glass → Air: θc = arcsin(1/1.52) = 41.14° — basis for optical fibers
  • Diamond → Air: θc = arcsin(1/2.417) = 24.44° — explains diamond's brilliance
  • Water → Air: θc = arcsin(1/1.333) = 48.59°

Applications of total internal reflection: optical fibers (glass core, critical angle ~41°, light bounces along for thousands of km), diamonds (low critical angle means most light reflects internally creating sparkle), binocular prisms (TIR replaces mirrors for image correction), medical endoscopes (fiber bundles carry images from inside the body).

Bending Toward or Away from the Normal

The key rule of refraction: comparing the angle of incidence and the angle of refraction tells you immediately which direction the light bends.

  • Entering denser medium (n₂ > n₁): θ₂ < θ₁ — bends TOWARD the normal
  • Entering less dense medium (n₂ < n₁): θ₂ > θ₁ — bends AWAY from the normal
  • Normal incidence (θ₁ = 0°): θ₂ = 0° always — light passes straight through without bending, regardless of the refractive index difference

The normal is always the reference: A ray hitting a glass surface at 45° to the surface has an angle of incidence of 90° - 45° = 45° to the normal. Students who measure from the surface instead of the normal get systematically wrong answers. The ray diagram above draws the normal explicitly — always use it as your reference.

Refractive Index of Common Materials — Reference Table

All values at 589 nm (sodium D-line), the standard reference wavelength. The refractive index is slightly different at other wavelengths — this variation is called dispersion, and it is why prisms split white light into colors.

Why does diamond have such a high refractive index (n=2.417)? Diamond's crystal structure causes very strong light-matter interaction — its electrons are tightly held and respond powerfully to electromagnetic radiation, slowing light dramatically. This high refractive index, combined with the very low critical angle (24.44°), means nearly all light entering a diamond undergoes total internal reflection multiple times before exiting — creating the characteristic sparkle when the diamond is cut with many facets.

Vacuum has exactly n = 1.000000 by definition — it is the reference medium. Air is only n = 1.00029, so for most practical calculations, treating air as having n = 1.000 introduces an error of only 0.03%.

Optical Fibers — Total Internal Reflection in Action

Optical fibers are the most important application of total internal reflection. A glass core (n_core ≈ 1.50) is surrounded by cladding glass (n_cladding ≈ 1.46). Light entering the fiber within the acceptance cone undergoes repeated TIR at the core-cladding interface, bouncing along the fiber with essentially zero loss.

Critical angle at core-cladding interface: θc = arcsin(1.46/1.50) = arcsin(0.973) = 76.7°. Any ray making an angle greater than 76.7° with the normal to the interface (i.e., traveling mostly along the fiber axis) undergoes TIR and stays trapped in the fiber.

Numerical Aperture: NA = sin(acceptance angle) = √(n_core² − n_cladding²) = √(1.50² − 1.46²) = √(2.25 − 2.1316) = √0.1184 ≈ 0.344.

This principle allows light to carry internet data across ocean floors — transatlantic fiber cables carry terabits per second using total internal reflection to guide photons for thousands of kilometers with amplification only every 80 km or so.

Common Mistakes in Snell's Law Calculations

Mistake 1 — Measuring Angles from the Surface, Not the Normal

  • ❌ Wrong: A ray hitting a glass surface at 30° to the surface → θ₁ = 30°
  • ✅ Correct: θ₁ = 90° − 30° = 60° (always measure from the normal to the interface)
  • The ray diagram shows the normal explicitly — always use it as the reference

Mistake 2 — Confusing n₁ and n₂

  • n₁ is always the medium the light is COMING FROM (incident medium)
  • n₂ is always the medium the light is ENTERING (refracted medium)
  • ❌ Wrong: "Light goes from glass into water, so n₁ = n_water" — no! n₁ = n_glass (source medium)

Mistake 3 — Expecting TIR in the Wrong Direction

  • ❌ Wrong: "Light going from air (n=1.00) into glass (n=1.52) — can TIR occur?" No — TIR only occurs going from DENSER to LESS DENSE (n₁ > n₂)
  • ✅ Correct: TIR requires n₁ > n₂ (light traveling into a less dense medium)

Mistake 4 — Reporting sin(θ₂) Instead of θ₂

  • ❌ Wrong: sin(θ₂) = 0.375, so "θ₂ = 0.375°"
  • ✅ Correct: sin(θ₂) = 0.375 → θ₂ = arcsin(0.375) = 22.03°. Always apply arcsin to find the actual angle of refraction

Mistake 5 — Using Degrees Directly in sin() Without Conversion

  • In programming: Math.sin() expects radians, not degrees
  • ✅ Correct: sin(30°) in code = Math.sin(30 × π/180) = Math.sin(0.5236) = 0.5000
  • Using Math.sin(30) gives sin(30 radians) = −0.988 — completely wrong

Worked Examples — 8 Complete Problems

1. Air → Water, θ₁ = 30° (angle of refraction)

  1. n₁sinθ₁ = n₂sinθ₂: 1.000 × sin(30°) = 1.333 × sinθ₂
  2. sinθ₂ = 0.5/1.333 = 0.37509
  3. θ₂ = 22.03° — bends toward normal (denser medium)

2. Air → Diamond, θ₁ = 45°

  1. sinθ₂ = 1.000 × sin(45°)/2.417 = 0.7071/2.417 = 0.2926
  2. θ₂ = 17.00° — dramatic bending due to high refractive index of diamond

3. Water → Air, θ₁ = 40° (bends away from normal)

  1. sinθ₂ = 1.333 × sin(40°)/1.000 = 0.8569
  2. θ₂ = 58.98° — bends away from normal (entering less dense medium)

4. Find n of Unknown: θ₁=45°, θ₂=28°

  1. n₂ = n₁sinθ₁/sinθ₂ = 1.000 × 0.7071/0.4695 = 1.506
  2. Closest match: Crown glass (n=1.52) or Flint glass (n=1.62)

5. Critical Angle: Glass (1.52) → Air

  1. sinθc = n₂/n₁ = 1.000/1.520 = 0.65789
  2. θc = arcsin(0.65789) = 41.14°

6. Critical Angle: Diamond (2.417) → Air

  1. sinθc = 1.000/2.417 = 0.41374
  2. θc = 24.44° — very low critical angle explains diamond's brilliant sparkle

7. Glass (1.52) → Water (1.333) at θ₁=70°: Does TIR occur?

  1. θc = arcsin(1.333/1.52) = arcsin(0.8770) = 61.28°
  2. Since 70° > 61.28° → YES, TIR occurs
  3. Check: sinθ₂ = 1.52×sin(70°)/1.333 = 1.070 > 1 → confirmed TIR

8. Speed of Light in Glass (n=1.52)

  1. v = c/n = 2.99792458×10⁸ / 1.52 = 1.972×10⁸ m/s
  2. Light travels at 65.8% of c inside crown glass

Frequently Asked Questions

What is Snell's law?
Snell's law (law of refraction) states: n₁sinθ₁ = n₂sinθ₂. Here n₁, n₂ are refractive indices of the two media, and θ₁, θ₂ are the angles of incidence and refraction measured from the normal (perpendicular to the interface). The Snell law equation describes how light bends when moving between media of different optical density.
What is the formula for angle of refraction?
The angle of refraction formula is θ₂ = arcsin(n₁ × sinθ₁ / n₂), derived from Snell's law n₁sinθ₁=n₂sinθ₂. Steps: (1) compute n₁sinθ₁, (2) divide by n₂ to get sinθ₂, (3) apply arcsin. Example: air→water at 30°: θ₂ = arcsin(1.000×0.500/1.333) = arcsin(0.3751) = 22.03°.
What is refractive index?
The refractive index n = c/v, where c = 2.998×10⁸ m/s is the speed of light in vacuum and v is the speed in the medium. It equals λ_vacuum/λ_medium. Always n ≥ 1 for ordinary materials. Examples: vacuum=1.000 (by definition), air=1.00029, water=1.333, crown glass=1.520, diamond=2.417.
Why does light bend when entering water?
Light bends because it travels at different speeds in different media. In water (n=1.333), light slows to c/1.333 = 2.249×10⁸ m/s. This speed change causes the wavefront to tilt according to Snell's law n₁sinθ₁=n₂sinθ₂. The higher the refractive index difference, the more bending occurs. This is why a straw appears bent in a glass of water.
What is total internal reflection?
Total internal reflection (TIR) occurs when (1) light travels from denser to less dense medium (n₁ > n₂) AND (2) angle of incidence exceeds the critical angle θc = arcsin(n₂/n₁). No refracted ray is produced — all light reflects back. The critical angle for glass→air is 41.14°. This is the principle behind optical fibers and explains diamond's sparkle.
What is the critical angle?
The critical angle θc = arcsin(n₂/n₁) is the angle of incidence at which the refracted ray travels along the interface (θ₂=90°). For any θ₁ > θc: total internal reflection occurs. Requires n₁ > n₂. Examples: glass(1.52)→air: θc=41.14°; diamond(2.417)→air: θc=24.44°; water(1.333)→air: θc=48.59°.
How do optical fibers work?
Optical fibers use total internal reflection. A glass core (n≈1.50) is surrounded by cladding (n≈1.46). The critical angle at the core-cladding interface is arcsin(1.46/1.50) ≈ 76.7°. Light entering within the acceptance cone undergoes repeated TIR — bouncing along the fiber with zero loss. This carries internet data across oceans at the speed of light.
Can refractive index be less than 1?
For ordinary materials at visible wavelengths, n ≥ 1 (light cannot exceed c in normal media). However, in exotic metamaterials engineered with specific nanostructures, negative or near-zero refractive indices are possible. For all practical optics and the refractive index calculator above, n ≥ 1 always applies.

Related Calculators

Quick Formulas
n₁sin(θ₁) = n₂sin(θ₂) Snell's law — core equation
θ₂ = arcsin(n₁sinθ₁/n₂) Angle of refraction formula
θc = arcsin(n₂/n₁) Critical angle (n₁>n₂ required)
n = c/v n from speed of light
n = λ_vac / λ_med n from wavelength change
n₂ = n₁sinθ₁/sinθ₂ Solve for refractive index
c = 2.99792458×10⁸ m/s Speed of light in vacuum
Quick Examples
Air→Water 30° → 22.03°
Air→Glass 45°
Air→Diamond 45°
Glass→Air 50° TIR!
θc: Glass→Air=41.14°
θc: Diamond=24.44°
Common n Values
Air: n = 1.00029 ≈ 1.000 for most calcs
Water: n = 1.3330 θc(water→air) = 48.59°
Crown glass: n = 1.5200 θc(glass→air) = 41.14°
Diamond: n = 2.4170 θc(diamond→air) = 24.44°
Fused silica: n = 1.4584 Fiber optic core material

Share This Tool

Share the Refractive Index Calculator with physics students!

Free chemistry, physics, biology & math calculators with step-by-step solutions. Trusted by 100,000+ students. Solve any science problem instantly!

Newsletter

Subscribe to our Newsletter to be updated. We promise not to spam.

Copyright © 2026 SciSolveLab. All Rights Reserved

Scroll to Top