We describe a quantum state transfer protocol, where a quantum state of photons stored in a first cavity can be faithfully transferred to a second distant cavity via an infinite 1D waveguide, while being immune to arbitrary noise (e.g., thermal noise) injected into the waveguide. We extend the model and protocol to a cavity QED setup, where atomic ensembles, or single atoms representing quantum memory, are coupled to a cavity mode. We present a detailed study of sensitivity to imperfections, and apply a quantum error correction protocol to account for random losses (or additions) of photons in the waveguide. Our numerical analysis is enabled by matrix product state techniques to simulate the complete quantum circuit, which we generalize to include thermal input fields. Our discussion applies both to photonic and phononic quantum networks. DOI: 10.1103/PhysRevLett.118.133601 Introduction.-The ability to transfer quantum states between distant nodes of a quantum network via a quantum channel is a basic task in quantum information processing [1][2][3][4]. An outstanding challenge is to achieve quantum state transfer [5,6] (QST) with high fidelity despite the presence of noise and decoherence in the quantum channel. In a quantum optical setup, the quantum channels are realized as 1D waveguides, where quantum information is carried by "flying qubits" implemented either by photons in the optical [7][8][9] or microwave regime [10-13], or phonons [14,15]. Thus, imperfections in the quantum channel include photon or phonon loss, and, in particular for microwave photons and phonons, a (thermal) noise background [16]. In this Letter, we propose a QST protocol and a corresponding quantum optical setup which allow for state transfer with high fidelity, undeterred by these imperfections. A key feature is that our protocol and setup are a priori immune to quantum or classical noise injected into the 1D waveguide, while imperfections such as random generation and loss of photons or phonons during transmission can be naturally corrected with an appropriate quantum error correction (QEC) scheme [17].The generic setup for QST in a quantum optical network is illustrated in Fig. 1 as transmission of a qubit state from a first to a second distant two-level atom via an infinite 1D bosonic open waveguide. The scheme of Fig. 1(a) assumes a chiral coupling of the two-level atoms to the waveguide [18,19], as demonstrated in recent experiments with atoms [20] and quantum dots [21]. The atomic qubit is transferred in a decay process with a time-varying coupling to a rightmoving photonic (or phononic) wave packet propagating in the waveguide, i.e., Ă°c g jgi 1 ĂŸ c e jei 1 Ăj0i p â jgi 1 Ă°c g j0i p ĂŸ c e j1i p Ă where ji 1 and ji p denote the atomic and channel states. The transfer of the qubit state is then completed by