Quantum key distribution (QKD offers a long-term solution to establish information-theoretically secure keys between two distant users. In practice, with a careful characterization of quantum sources and the decoy-state method, measure-device-independent quantum key distribution (MDI-QKD) provides secure key distribution. While short-distance fibre-based QKD has already been available for real-life implementation, the bottleneck of practical QKD lies on the limited transmission distance. Due to photon losses in transmission, it was believed that the key generation rate is bounded by a linear function of the channel transmittance, $O(\eta)$, without a quantum repeater, which puts an upper bound on the maximal secure transmission distance. Interestingly, a new phase-encoding MDI-QKD scheme, named twin-field QKD, has been suggested to beat the linear bound, while another variant, named phase-matching quantum key distribution (PM-QKD), has been proven to have a quadratic key-rate improvement, $O(\sqrt{\eta})$. In reality, however, the intrinsic optical mode mismatch of independent lasers, accompanied by phase fluctuation and drift, impedes the successful experimental implementation of the new schemes. Here, we solve this problem with the assistance of the laser injection technique and the phase post-compensation method. In the experiment, the key rate surpasses the linear key-rate bound via 302 km and 402 km commercial-fibre channels, achieving a key rate over 4 orders of magnitude higher than the existing results in literature. Furthermore, with a 502 km ultralow-loss fibre, our system yields a secret key rate of 0.118 bps. We expect this new type of QKD schemes to become a new standard for future QKD.