Crossing a boundary vs going around an edge

Diffraction vs Refraction

The difference between diffraction and refraction is what makes the wave change direction: refraction is the bending of a wave as it passes from one medium into another and changes speed, while diffraction is the spreading of a wave around an obstacle or through an opening without changing medium. Refraction follows Snell's law; diffraction is strongest when the gap is about one wavelength wide.

Ocean waves passing through a narrow gap in a harbor breakwater and spreading into curved ripples, a large-scale example of diffraction
Waves passing a gap in a breakwater spread out by diffraction without entering a new medium.

At a Glance

Refraction happens at a boundary between two media, where a change in wave speed bends the wave according to Snell's law, n1 sin θ1 = n2 sin θ2. Diffraction happens at edges and gaps within one medium, where the wave spreads out; for a single slit the first dark band sits at a sin θ = λ. Refraction changes the wave's speed and wavelength, while diffraction changes neither.

Refraction
Bending at a boundary between media
Diffraction
Spreading around edges and through gaps
Cause
Speed change vs obstruction of part of the wavefront
Key equations
n1 sin θ1 = n2 sin θ2 vs a sin θ = m λ
Speed and wavelength
Refraction changes both · Diffraction changes neither
On this page
  1. What Is the Difference Between Diffraction and Refraction?
  2. How Are Diffraction and Refraction Defined?
  3. What Equations Describe Diffraction and Refraction?
  4. What Does Refraction Look Like in a Ray Diagram?
  5. Why Does Diffraction Depend on the Size of the Gap?
  6. Do Speed, Wavelength and Frequency Change?
  7. What Are Examples of Diffraction and Refraction?
  8. Where Can You Go Next?
  9. Common Misconceptions
  10. Key Facts
  11. Quiz
  12. FAQ

What Is the Difference Between Diffraction and Refraction?

Both diffraction and refraction make waves change direction, so they are easy to mix up. The cause is what separates them. Refraction is bending caused by a change of medium: the wave crosses a boundary, its speed changes, and its path tilts. Diffraction is spreading caused by an obstacle: part of the wave is blocked, and the rest fans out into the shadow region behind the edge.

A simple test usually settles it. Ask whether the wave entered a different material. If light went from air into glass or water, you are looking at refraction. If it stayed in air but squeezed through a slit or curled around an edge, you are looking at diffraction.

The table below lines them up point by point, and the sections after it give the formulas, worked numbers and everyday examples.

Diffraction and refraction compared side by side
FeatureDiffractionRefraction
What happensWave spreads around edges or through gapsWave bends as it crosses into a new medium
CausePart of the wavefront is blockedWave speed changes at a boundary
Number of mediaOneTwo (or a medium whose properties vary)
Speed of the waveUnchangedChanges
WavelengthUnchangedChanges in proportion to speed
FrequencyUnchangedUnchanged
Key equationa sin θ = m λ (single slit, dark bands)n1 sin θ1 = n2 sin θ2 (Snell's law)
Depends on gap size?Yes, strongest near one wavelengthNo
Can be drawn with rays?No, needs the wave modelYes
Typical light patternBright and dark bands, fuzzy edgesA shifted image or a spectrum
Happens to sound too?Yes, very noticeablyYes, for example near the ground at night
Everyday exampleHearing around a cornerA straw looking bent in water
Source: Definitions as used in standard wave optics; examples are illustrative · Retrieved October 2026

How Are Diffraction and Refraction Defined?

Refraction is the change in direction of a wave when it passes at an angle from one medium into another in which it travels at a different speed. Light entering water slows down and bends toward the normal, the line perpendicular to the surface. Light leaving water speeds up and bends away from it. A wave that hits the boundary head-on slows down but does not bend.

Diffraction is the spreading of a wave as it passes the edge of an obstacle or goes through an opening. The wave does not enter a new material, and its speed stays the same. Behind the opening it fans out, and with light it often forms a pattern of bright and dark bands.

The Italian scientist Francesco Grimaldi described and named diffraction in the 1660s. The law of refraction was found earlier in the 1600s, and today carries the name of Willebrord Snellius.

What Equations Describe Diffraction and Refraction?

Refraction is governed by Snell's law, n1sin⁡θ1=n2sin⁡θ2. The angles are measured from the normal, and n is the index of refraction of each medium, the ratio of the speed of light in a vacuum to its speed in that medium.

Diffraction through a single narrow slit is described by asin⁡θ=mλ, which gives the angles of the dark bands for m=±1,±2,…. Here a is the slit width and λ is the wavelength. The full derivation lives on our single-slit diffraction page.

Notice what each equation contains. Snell's law has indices of refraction, which describe materials, and no wavelength or gap size. The diffraction equation has wavelength and gap size, and no material property at all. To solve refraction angles quickly, use our Snell's law calculator.

Here is Snell's law, the rule that sets the angle of a refracted ray, with each variable and its unit.

n1sin⁡θ1=n2sin⁡θ2
What each symbol means
SymbolQuantitySI unit
n1index of refraction of medium 1dimensionless (1)
θ1angle of incidence (from the normal)radian (rad)
n2index of refraction of medium 2dimensionless (1)
θ2angle of refraction (from the normal)radian (rad)

Rearranged to find another variable:

θ2=arcsin(n1sin⁡θ1n2)n2=n1sin⁡θ1sin⁡θ2θ1=arcsin(n2sin⁡θ2n1)n1=n2sin⁡θ2sin⁡θ1

Valid for: angles from the normal.

Example 1 A laser pointer aimed into an aquarium

A laser beam in air (n1 = 1.00) strikes the flat water surface of an aquarium at 45° (0.7854 rad) from the normal. The water has n2 = 1.33. At what angle from the normal does the beam travel in the water?

  1. Given:
    • index of refraction of medium 1: n1=1
    • angle of incidence (from the normal): θ1=0.7854 rad
    • index of refraction of medium 2: n2=1.33
  2. Formula: θ2=arcsin(n1sin⁡θ1n2)
  3. Substitute: n1=1,θ1=0.7854 rad,n2=1.33
  4. Answer: θ2=32.12 °

The angle is smaller than 45°, so the beam bends toward the normal as it slows down in the water.

What Does Refraction Look Like in a Ray Diagram?

Refraction is easy to draw with straight rays, because it happens at a sharp boundary. The diagram below shows a ray going from air into water at 45° from the normal. Snell's law sends it into the water at a smaller angle, so it bends toward the normal. A weaker reflected ray also bounces off the surface.

Diffraction cannot be drawn with simple rays. It needs the wave picture, in which every point on a wavefront acts as a source of new wavelets, an idea known as Huygens' principle. When part of a wavefront is cut off by an edge, the remaining wavelets spread sideways into the region that rays alone would leave dark.

Ray diagram of light passing from air into water at 45 degrees and bending toward the normal, with a weak reflected ray
Refraction: the ray slows down entering water and bends toward the normal, as Snell's law predicts.

Why Does Diffraction Depend on the Size of the Gap?

Diffraction is strongest when the opening or obstacle is about as wide as the wavelength. A gap much wider than the wavelength lets the wave pass almost straight through, with only slight spreading at the edges. A gap close to one wavelength turns the wave into nearly circular ripples on the far side.

This explains a puzzle from daily life: you can hear a friend around a corner but cannot see them. A 343 Hz tone has a wavelength of about 1 m in air (computed from a typical sound speed of 343 m/s), similar to a doorway, so sound bends around it readily. Visible light has wavelengths of roughly 400 to 700 nanometers, millions of times smaller, so the same doorway barely diffracts it.

Refraction has no such size rule. A raindrop, a swimming pool and an ocean all refract light, because what matters is the change in speed at the boundary.

Example 2 Red laser through a narrow slit

A red laser of wavelength 650 nm shines through a single slit 0.04 mm wide. At what angle from the center line does the first dark band (m = 1) appear?

  1. Given:
    • slit width: a=4×10−5 m
    • order of the minimum (non-zero integer): m=1
    • wavelength: λ=6.5×10−7 m
  2. Formula: θ=arcsin(mλa)
  3. Substitute: a=4×10−5 m,m=1,λ=6.5×10−7 m
  4. Answer: θ=0.9311 °

The angle is about a degree, so the central bright band on a wall a few meters away is several centimeters wide. A narrower slit would spread it further.

Do Speed, Wavelength and Frequency Change?

In refraction, the wave's speed changes, and so does its wavelength, while its frequency stays fixed by the source. Light entering water slows down to about three quarters of its speed in a vacuum, and its wavelength shrinks by the same factor. The color you see, which is set by frequency, does not change.

In diffraction, nothing about the wave itself changes. It travels in the same medium at the same speed with the same wavelength and frequency. Only its direction spreads out, and its energy is shared out over a wider range of angles.

Refraction often also separates colors, because the index of refraction varies slightly with wavelength. That effect is called dispersion, and it is why a prism or a raindrop makes a spectrum.

Example 3 How fast light travels in water

Water has an index of refraction of 1.33. Using c = 299,792,458 m/s, what is the speed of light in water?

  1. Given:
    • speed of light in vacuum: c=299,792,458 m/s
    • index of refraction: n=1.33
  2. Formula: v=cn
  3. Substitute: c=299,792,458 m/s,n=1.33
  4. Answer: v=225,400,000 m/s (811,500,000 km/h, 504,200,000 mph)

This drop in speed at the surface is the root cause of refraction. Diffraction involves no such speed change.

What Are Examples of Diffraction and Refraction?

Everyday examples of refraction:

  • A straw in a glass of water looks broken at the surface.
  • A swimming pool looks shallower than it really is.
  • Eyeglasses, camera lenses and magnifying glasses focus light by refraction.
  • On hot roads, layers of warm air bend light and create mirages.

Everyday examples of diffraction:

  • You hear music from a room down the hall through the open door.
  • Long-wavelength radio signals reach valleys behind hills.
  • Ocean waves spread out after passing through a gap in a harbor wall.
  • The edges of a shadow look slightly fuzzy when you look very closely.

Some effects involve both. A rainbow is mainly refraction, dispersion and reflection inside raindrops, but diffraction adds the faint extra bands sometimes seen just inside the main bow.

Where Can You Go Next?

Diffraction has a close partner, interference, which produces the bright and dark bands in diffraction patterns; the two are compared on diffraction vs interference. Refraction pairs naturally with bouncing light, covered in reflection vs refraction. For printable practice problems on both, see our light worksheets.

Common Misconceptions

Myth: Diffraction and refraction are two names for bending light.

Physics: Both change a wave's direction, but for different reasons. Refraction is caused by a change of speed at a boundary; diffraction is caused by an obstacle or opening that blocks part of the wave.

Myth: Diffraction only happens to light.

Physics: Every kind of wave diffracts. Sound and water waves show it more obviously than light because their wavelengths are similar to the size of everyday objects.

Myth: Refraction changes the color of light.

Physics: Color is set by frequency, which does not change during refraction. Refraction can separate colors that were mixed, as in a prism, but it does not turn one color into another.

Myth: Light passing through a big window diffracts strongly.

Physics: A window is millions of wavelengths wide, so light passes almost straight through. Noticeable diffraction of light needs very narrow slits or fine edges.

Key Facts

  • Refraction is the bending of a wave as it passes from one medium into another and changes speed.
  • Diffraction is the spreading of a wave around an obstacle or through an opening within a single medium.
  • Refraction follows Snell's law, n1 sin θ1 = n2 sin θ2.
  • Diffraction is strongest when the gap or obstacle is about one wavelength across.
  • Refraction changes a wave's speed and wavelength; diffraction changes neither.
  • Sound diffracts around doorways easily because its wavelengths are similar in size to everyday openings.
  • Both effects happen to all kinds of waves, including light, sound and water waves.
Did you know? Ocean waves refract too: as they approach a sloping beach they slow down in shallower water, which swings their crests around until they arrive nearly parallel to the shore, whatever direction they started from.

Quick Quiz: How Well Do You Know Diffraction vs Refraction?

6 questions. Tap an answer to check it.

  1. What causes refraction?

  2. Diffraction is strongest when the opening is

  3. Which quantity stays the same when light refracts from air into water?

  4. Hearing a radio from the next room through an open door is mainly an example of

  5. Which equation describes refraction?

  6. A pool looks shallower than it really is because of

Frequently Asked Questions

What is the main difference between diffraction and refraction?

Refraction is the bending of a wave when it moves from one medium into another and changes speed, such as light passing from air into water. Diffraction is the spreading of a wave when it passes an edge or goes through a narrow opening, without changing medium. Refraction depends on the materials; diffraction depends on the size of the gap compared with the wavelength.

Is a rainbow caused by diffraction or refraction?

A rainbow is caused mainly by refraction. Sunlight bends as it enters a raindrop, reflects off the back of the drop and bends again on the way out. Because each color bends by a slightly different amount, the colors separate. Diffraction plays only a small role, producing the faint extra bands sometimes seen inside the main bow.

Why can we hear around corners but not see around them?

Sound waves have wavelengths from centimeters to meters, similar in size to doors and hallways, so they diffract strongly around them. Visible light has wavelengths of a few hundred nanometers, far smaller than a doorway, so it barely spreads at all. That is why sound reaches you around a corner while light travels on in nearly straight lines.

Does the speed of a wave change in diffraction?

No. During diffraction the wave stays in the same medium, so its speed, wavelength and frequency all stay the same. Only its direction spreads out. In refraction the speed does change, and the wavelength changes with it, while the frequency remains fixed by the source that produced the wave.

Do diffraction and refraction happen to sound waves?

Yes. Sound diffracts around buildings, doorways and hills, which is why you can hear things you cannot see. Sound also refracts when it passes through air layers at different temperatures. At night, cooler air near the ground can bend sound back downward, helping distant sounds travel farther than they do during the day.

Which explains why a straw looks bent in water?

Refraction. Light from the underwater part of the straw speeds up as it leaves the water and bends away from the normal at the surface. Your brain assumes light travels in straight lines, so it places that part of the straw in a slightly different spot from where it really is, making the straw look broken.

Can diffraction be explained with rays?

No. The ray model treats light as traveling in straight lines, which works well for refraction and reflection but predicts perfectly sharp shadows. Diffraction needs the wave model, where every point on a wavefront sends out new wavelets. When an edge blocks part of the wavefront, those wavelets spread into the shadow region.

What is the formula for diffraction?

For a single narrow slit, the dark bands in the pattern appear at angles that satisfy a sin θ = m λ, where a is the slit width, λ is the wavelength and m is a whole number other than zero. Gratings with many slits use the similar equation d sin θ = m λ, where d is the spacing between neighboring lines.

Physics Tribune Editorial Team
Written by our editors and checked against NIST and BIPM reference data. Every worked example is recomputed in code. Read our editorial policy. Last updated October 2026.