Of late, image compression has become crucial due to the rising need for faster encoding and decoding. To achieve this objective, the present study proposes the use of canonical Huffman coding (CHC) as an entropy coder, which entails a lower decoding time compared to binary Huffman codes. For image compression, discrete wavelet transform (DWT) and CHC with principal component analysis (PCA) were combined. The lossy method was introduced by using PCA, followed by DWT and CHC to enhance compression efficiency. By using DWT and CHC instead of PCA alone, the reconstructed images have a better peak signal-to-noise ratio (PSNR). In this study, we also developed a hybrid compression model combining the advantages of DWT, CHC and PCA. With the increasing use of image data, better image compression techniques are necessary for the efficient use of storage space. The proposed technique achieved up to 60% compression while maintaining high visual quality. This method also outperformed the currently available techniques in terms of both PSNR (in dB) and bit-per-pixel (bpp) scores. This approach was tested on various color images, including Peppers 512 × 512 × 3 and Couple 256 × 256 × 3, showing improvements by 17 dB and 22 dB, respectively, while reducing the bpp by 0.56 and 0.10, respectively. For grayscale images as well, i.e., Lena 512 × 512 and Boat 256 × 256, the proposed method showed improvements by 5 dB and 8 dB, respectively, with a decrease of 0.02 bpp in both cases.