A cosmetic composition, in particular hair conditioner composition, comprising at least one oligoester ammonium salt and at least one further cosmetically acceptable component, whereby the at least one oligoester ammonium salt is obtainable by the following steps: (i) heating a mixture of the following components (a) to (d) under continuously removing of reaction water: 0.5 to 3.0 molar equivalents of a diethanolamine compound represented by the formula (a) wherein R 3 is a linear or branched C 1 -C 6 -alkyl, preferably linear or branched C 1 -C 4 -alkyl, more preferably methyl or ethyl; 0.5 to 1.5 molar equivalents of a dicarboxylic acid represented by the formula (b) wherein R 2 is a linear or branched C 1 -C 10 -alkylene or a linear or branched C 2 -C 10 -alkenylene, preferably C 2 -C 8 -alkylene, more preferably C 4 -alkylene; 0.5 to 1.5 molar equivalents of an organic triol represented by the formula (c) 1.0 molar equivalent of a monocarboxylic acid represented by formula (d) R 1 -COOH (d) wherein R 1 is linear or branched C 12 -C 24 -alkyl or linear or branched C 12 -C 24 -alkenyl, preferably linear or branched C 12 -C 22 -alkyl or linear or branched C 12 -C 22 -alkenyl, more preferably C 20 -C 22 -alkyl; (ii) reacting the oligoester product of step (i) with a quaternization agent (e), in particular from the group of dimethyl sulfate, diethyl sulfate and alkyl halides; (iii) optionally removing and purifying the at least one oligoester ammonium salt. (i) heating a mixture of the following components (a) to (d) under continuously removing of reaction water: 0.5 to 3.0 molar equivalents of a diethanolamine compound represented by the formula (a) wherein R 3 is a linear or branched C 1 -C 6 -alkyl, preferably linear or branched C 1 -C 4 -alkyl, more preferably methyl or ethyl; 0.5 to 1.5 molar equivalents of a dicarboxylic acid represented by the formula (b) wherein R 2 is a linear or branched C 1 -C 10 -alkylene or a linear or branched C 2 -C 10 -alkenylene, preferably C 2 -C 8 -alkylene, more preferably C 4 -alkylene; 0.5 to 1.5 molar equivalents of an organic triol represented by the formula (c) 1.0 molar equivalent of a monocarboxylic acid represented by formula (d) R 1 -COOH (d) wherein R 1 is linear or branched C 12 -C 24 -alkyl or linear or branched C 12 -C 24 -alkenyl, preferably linear or branched C 12 -C 22 -alkyl or linear or branched C 12 -C 22 -alkenyl, more preferably C 20 -C 22 -alkyl; 0.5 to 3.0 molar equivalents of a diethanolamine compound represented by the formula (a) wherein R 3 is a linear or branched C 1 -C 6 -alkyl, preferably linear or branched C 1 -C 4 -alkyl, more preferably methyl or ethyl; 0.5 to 1.5 molar equivalents of a dicarboxylic acid represented by the formula (b) wherein R 2 is a linear or branched C 1 -C 10 -alkylene or a linear or branched C 2 -C 10 -alkenylene, preferably C 2 -C 8 -alkylene, more preferably C 4 -alkylene; 0.5 to 1.5 molar equivalents of an organic triol represented by the formula (c) 1.0 molar equivalent of a monocarboxylic acid represented by formula (d) R 1 -COOH (d) (ii) reacting the oligoester product of step (i) with a quaternization agent (e), in particular from the group of dimethyl sulfate, diethyl sulfate and alkyl halides; (iii) optionally removing and purifying the at least one oligoester ammonium salt.