This works for all HTC One M8 variants like O2, VodaFone, T-Mobile etc.

HTC One M8 disable autocorrect

In HTC One you go to the Settings – Language & Keyboard – HTC Sense Input screen and toggle off .  Then move to Advanced Settings and click off Spell Correction and then Word Prediction.