Motivated by the close relationship between quantum error-correction, topological order, the holographic AdS/CFT duality, and tensor networks, we initiate the study of approximate quantum error-detecting codes in matrix product states (MPS). We first show that using open-boundary MPS to define boundary to bulk encoding maps yields at most constant distance error-detecting codes. These are degenerate ground spaces of gapped local Hamiltonians. To get around this no-go result, we consider excited states, i.e., we use the excitation ansatz to construct encoding maps: these yield error-detecting codes with distance Ω(n 1−ν ) for any ν ∈ (0, 1) and Ω(log n) encoded qubits. This shows that gapped systems contain -within isolated energy bands -error-detecting codes spanned by momentum eigenstates. We also consider the gapless Heisenberg-XXX model, whose energy eigenstates can be described via Bethe ansatz tensor networks. We show that it contains -within its low-energy eigenspace -an error-detecting code with the same parameter scaling. All these codes detect arbitrary d-local (not necessarily geometrically local) errors even though they are not permutation-invariant. This suggests that a wide range of naturally occurring many-body systems possess intrinsic errordetecting features.