Lossless compression is often required for downloading data of scientific payloads in space missions. The consultative committee for space data systems (CCSDS) 121.0 recommendation on lossless data compression is a “de-facto” standard, and it has been used in several missions so far owing to the reasonable compression ratios achieved with low processing requirements. Although the Rice coder used by this standard is optimal when dealing with noiseless Laplacian-distributed data, its performance rapidly degrades when noisy data are compressed or when there is a significant fraction of outliers in the input data. An alternative to this is PEC, the Prediction Error Coder, which is the core of the FAPEC adaptive entropy coder. We describe, analyze and test PEC on real and simulated data, revealing its key role in the excellent outlier resiliency of FAPEC. PEC is a fast and noise-resilient semi-adaptive entropy coder that can achieve better performances than the CCSDS standard in the presence of noise or when the input data contains a sizable fraction of outliers, while requiring very low processing resources.