They are surprisingly effective.
The best way to spread word about a product or a service is from one who is adored, admired and respected by many. Celebrities with their good looks and likeable personalities fits all this criteria. Plus they are often seen on national television, magazines and people are often looking forward to what they are up to in social media, so spending on celebrities for endorsement deals is an effective strategy.
Always remember that marketing is an intergral part of business companies and the easiest marketing they can do is to people through their celebrities. If they spend 1 million dollars on the endorsement, they are surely going to make 10 times that or maybe more in return. Also, many a times, those endorsements are paid out in stages and when certain goals and numbers are met.
It can be a risk if the celebrity they targeted does something stupid or gets involved in a scandal.
It is not a waste of money since these companies are sophisticated and employ smart people who allocate their marketing dollars accordingly.
Using celebrities for advertisement is an age-old strategy that has been used to promote products for thousands of years. Back in Roman times, cologne sellers would obtain sweat and blood from gladiators to sell to the audience, using the gladiator themselves as a way to promote their product.
Using celebrities for advertisement helps the company grow much more then a normal advertisement because they can appeal much more to that celebrity's audience. If Kendall Jenner was to be on an ad for perfume, people who follow her would trust her choice and purchase that perfume, and people who would see that ad anyways on TV, Kendall Jenner or not, would still be reached, and perhaps persuaded more by her celebrity status. At the end of the day, you just reach more people when using a celebrity to advertise, even if it might cost more.