The galaxy S5 has more features than the M8 and like the finger print scanner and heart rate monitor but they are slow with system updates. I don't know how good HTC is with their updates so you will have to ask around. If you like taking a lot of night time photos and videos then the M8 wins. It also has a simpler interface than the S5.
For the screens the S5 has an amoled screen which make for more vivid colours but oversaturate them a lot where as the M8 is a bit more natural. Its up to you which you prefer
Me personally I would choose the M8 over the S5 because of its look, curved nature and metallic body.
If you had to choose a different phone it would depend on what you do with it
I'm looking at the Samsung Galaxy S5 / Active and the HTC One (M8) and I really like them both; I need a third party opinion. Thanks!
The S5 goes better in specs than the M8 and has a fingerprint scanner and a better CPU than the M8
But if you are looking for a phone i would suggest the LG G3
The problem with the G3 is that it can overheat very easily as it can't dissipate the heat very well. Also outdoor usage is not good as the brightness drops as the phone heats up. This also affect performance. Read the notebookcheck review to find out more.
i have both smart phone but better is m8 bcoz i had recently bought them and i had send my samsung s5 many time to service centre till now but it is not fully repaired and samsung service is very bad (hanging smartphone)
but m 8 is never repaired till i have purchased it and it is more faster than s5 and much reliable
i suggest that you should go with m8