I think that CD’s and Streaming can sound equally good but in both cases it depends on the master used on both the CD and the copy the streaming service is using and it also depends on the electronics being used for each media source.
As far as CD’s go in many cases I prefer my old original AAD CD’s sourced and mastered from the original analog tapes but that is not 100%.
I run my Bluesound Node 2i through the DAC in my Moon 260D CD player and with balanced cables to my preamplifier. If the original source on both the CD and streamed file are good they will sound equally fantastic.