There are many different opinions about whether digital coaxial or optical cables are better, but our recommendation is to use coaxial cables for short routes in particular, and where the sound quality is important. For long cable routes, optical cables have certain advantages as there is not much resistance in a fibreoptic cable, compared to a coaxial one. However, this must be balanced against the potential losses in the transition from electric to light and back again in the devices to be connected. All this is primarily important to have in mind for high-end systems. When connecting regular receiver boxes, cheap DVD players, etc., you should consider what is the best solution in practical terms and the available connectivity.
For connecting, e.g. laptops, Google Chromecast Audio with SPDIF output, often a combined stereo and optical output are used, in the form of a MiniJack/MiniToslink connector. To connect such devices to a digital system,
MiniToslink - Toslink cables is used.