Escape of a granular chain from a pore in a wall in the presence of diffusing granular particles on one side of the wall is studied experimentally. The escape time shows power-law behavior as a function of the chain length (τ ∝ Nα). A Langevin dynamics simulation of a polymer chain in a similar geometry is also performed and similar results to those for a granular system are obtained. A simple scaling argument and an energetic argument (based on the Onsager principle) are introduced which explain our results very well. Experiments (simulations) show that by increasing the number of particles on one side of the wall from zero, the exponent α decreases from 2.6 ± 0.1 (3.1 ± 0.1) to about 2. Both scaling and the Onsager principle argument predict α = 2 at high particle concentration, in agreement with the experiments and simulations. In the absence of particles, the scaling predicts τ = N2.5 (in agreement with the experimental result for the granular chain) and the Onsager principle predictsτ = N3lnN, supporting the simulation result for the polymer chain. Experiments, simulations, scaling, and the Onsager principle confirm an inverse relation between τ and the density of particles on one side of the wall.