A stator assembly for an electrical machine comprises a stator, a plurality of inserts and a heat sink. The stator comprises an annular core extending around an axis (X) and a plurality of axially extending slots. A plurality of sets of electrical windings is arranged within the slots. The windings have axial end portions arranged at axial ends of the core. The inserts comprise ceramic plates which are arranged in respective slots in the gaps (G) between adjacent respective electrical windings in the slots. The inserts extend axially from the respective slots for engagement with the heat sink.