Quantum networks hold the promise for revolutionary advances in information processing with quantum resources distributed over remote locations via quantum-repeater architectures. Quantum networks are composed of nodes for storing and processing quantum states, and of channels for transmitting states between them. The scalability of such networks relies critically on the ability to perform conditional operations on states stored in separated quantum memories. Here we report the first implementation of such conditional control of two atomic memories, located in distinct apparatuses, which results in a 28-fold increase of the probability of simultaneously obtaining a pair of single photons, relative to the case without conditional control. As a first application, we demonstrate a high degree of indistinguishability for remotely generated single photons by the observation of destructive interference of their wavepackets. Our results demonstrate experimentally a basic principle for enabling scalable quantum networks, with applications as well to linear optics quantum computation.