In this paper, an algorithm for image coding based on a sparse 3-dimensional Discrete Cosine Transform (3D DCT) is studied. The algorithm is essentially a method for achieving a sufficiently sparse representation using 3D DCT. The experimental results obtained by the algorithm are compared to the 2D DCT (used in JPEG standard) and wavelet db9/7 (used in JPEG2000 standard). It is experimentally shown that the algorithm, that only uses DCT but in 3 dimensions, outperforms the DCT used in JPEG standard and achieves comparable results (but still less than) the wavelet transform.