A lottery is a game of chance in which numbers or symbols are drawn at random for a prize. Lotteries are typically run by a government or other public entity, and their popularity has given rise to many ethical issues. These include questions of the societal desirability and acceptability of gambling as a source of revenue, and concerns about the effect of promoting gambling on vulnerable groups such as the poor, problem gamblers, and children.

The first recorded lotteries were held in the Low Countries in the 15th century for raising money to build town fortifications and help the needy. The word “lottery” is thought to be derived from Middle Dutch loterie, a compound of lot (“a random choice”) and erie (“drawing”).

In modern times, state lotteries are a widespread activity in most developed nations, with the majority of states having one or more. They are generally operated as businesses that seek to maximize revenues through marketing and promotional efforts, including extensive advertising. This has generated ethical concerns over the societal desirability and acceptability for gambling, as well as questions of whether lotteries are appropriate functions for governments to undertake.

The success of a lottery depends on the amount of money returned to bettors in winnings, which is usually between 40 and 60 percent of the total pool. There are several factors that affect this percentage, including the probability of a win, how many numbers are selected, and the overall odds of winning.