Bonjour,
That's a very interesting question!
When placed in front of a noun or an adjective, you will write it as such "demi":
une demi-heure = a half hour / half an hour
des demi-frères = half brothers
du vin demi-sec = semi dry wine
However when placed after a noun, it does not take an -s to mark the plural form but changes according to the gender of the noun:
Il est cinq heures et demie du matin = It is half past five AM
Je pars quatre mois et demi = I am leaving for four and a half months
I hope this is helpful.
Bonne journée !