As a result of processing data in the form of documents too often, document files accumulate on storage media and make the storage media lack free space. One solution that can prevent this is data compression. In this study, we will try to analyze the performance of lossless algorithms, some of which are: Goldbach's Algorithm, Fibonacci's Algorithm, Rice Codes Algorithm, Additive Codes, and Yamamoto's Recursive Codes Algorithm. The main reason why a comparison is needed is to see which algorithm is the best, it is worth doing as a basis for making applications that can compress data because application users want the best results for them, and in this case, are those that can compress files and produce the smallest size compared to other algorithms. The data to be compressed is text data. The results obtained from the test are the Goldbach Codes and Fibonacci Codes algorithms are superior to the third algorithm and several times have the same results, namely compression ratios of 60% to 68% and space savings ranging from 32% to 40%.