Assuming a relatively constant rate of expansion over time, the most distant galaxies observed must have been much closer at the time the light we now see left the galaxy. Why did that light not arrive here much sooner?
How we Know the Universe Is Expanding
Beginning in the 1920s, Edwin Hubble used the 100 inch telescope on Mount Wilson to measure the distances to galaxies using Cepheid variable stars as distance indicators.
Hubble also studied the spectra of galaxies and found that all but the nearest galaxies had a Doppler redshift in their spectra.
Doppler redshifts tell us that an astronomical object is moving away from us.
Larger redshifts indicate larger recessional velocities, or objects that are moving away faster.
When Hubble graphed the recessional velocities of galaxies versus their distances, he found a linear relationship. The more distant galaxies appeared to be moving away from us more rapidly. Astronomers call this graph the Hubble plot or Hubble’s law.
Hubble then deduced the reason for this effect: The universe is expanding. The slope of the Hubble plot, called the Hubble constant, tells astronomers how fast the universe is expanding and allows astronomers to calculate the age of the universe in the context of the big bang model. Astronomers also use Hubble’s law to calculate the distances to very distant galaxies from their measured redshifts.
To visualize why Hubble’s law tells astronomers the universe is expanding, draw a bunch of dots on a balloon. Then watch the dots while blowing up the balloon. From the vantage point of any given dot all the other dots will appear to be moving away with the more distant dots moving away more rapidly. Graphing the apparent recessional velocities of the dots on the balloon versus their distances will give a graph very similar (on a much smaller scale) to Hubble’s plot.
The slope of the Hubble plot is approximately, but not exactly, constant over time. The 2011 Nobel Prize in Physics was awarded to Saul Perlmutter, Brian Schmidt, and Adam Riess for their discovery that the rate at which the universe is expanding is accelerating.
Light Travel and Lookback Times
When astronomers observe a distant galaxy, they are observing the galaxy as it was in the past when the light left the galaxy.
For example, the Andromeda galaxy (the closest giant spiral galaxy to the Milky Way) is about 2 million light years away.
Hence astronomers see the Andromeda galaxy as it was 2 million years ago, and the Andromeda galaxy has a lookback time of 2 million years.
Although 2 million years sounds like an eternity to us, it is barely a blip on cosmic time scales, so the Andromeda galaxy has not changed significantly during its 2 million year lookback time.
For more distant galaxies, however, this light travel time becomes important.
If a galaxy is 2 billion (2E9), rather than 2 million (2E6), light years away astronomers are seeing the galaxy as it was about 2 billion years ago.
The galaxy may have changed significantly during the time that its light was traveling to reach us.
Expanding Universe and Moving Galaxies
More relevant to the question: Because the universe is expanding, the galaxy will have moved further away from us during the time its light was traveling to reach us, so the distance to the galaxy in light years does not exactly equal the number of years ago the light left the galaxy. When computing the distance to a distant galaxies, and how long ago the light left a galaxy, astronomers must correct for the expansion of the universe.
In other words: The distance that a distant galaxy travels away from us during the light travel time is a very small fraction of the distance to the galaxy, but it is not zero.