Long-distance quantum teleportation and quantum repeater technologies require entanglement between a single matter quantum bit (qubit) and a telecommunications (telecom)-wavelength photonic qubit. Electron spins in III-V semiconductor quantum dots are among the matter qubits that allow for the fastest spin manipulation and photon emission, but entanglement between a single quantum-dot spin qubit and a flying (propagating) photonic qubit has yet to be demonstrated. Moreover, many quantum dots emit single photons at visible to near-infrared wavelengths, where silica fibre losses are so high that long-distance quantum communication protocols become difficult to implement. Here we demonstrate entanglement between an InAs quantum-dot electron spin qubit and a photonic qubit, by frequency downconversion of a spontaneously emitted photon from a singly charged quantum dot to a wavelength of 1,560 nanometres. The use of sub-10-picosecond pulses at a wavelength of 2.2 micrometres in the frequency downconversion process provides the necessary quantum erasure to eliminate which-path information in the photon energy. Together with previously demonstrated indistinguishable single-photon emission at high repetition rates, the present technique advances the III-V semiconductor quantum-dot spin system as a promising platform for long-distance quantum communication.