Using results from high-resolution galaxy formation simulations in a standard Lambda-CDM cosmology and a fully conservative multi-resolution radiative transfer code around point sources, we compute the energy-dependent escape fraction of ionizing photons from a large number of star forming regions in two galaxies at five different redshifts from z=3.8 to 2.39. All escape fractions show a monotonic decline with time, from (at the Lyman-limit) ~6-10% at z=3.6 to ~1-2% at z=2.39, due to higher gas clumping at lower redshifts. It appears that increased feedback can lead to higher f_esc at z>3.4 via evacuation of gas from the vicinity of star forming regions and to lower f_esc at z<2.39 through accumulation of swept-up shells in denser environments. Our results agree well with the observational findings of citet{inoue..06} on redshift evolution of f_esc in the redshift interval z=2-3.6.