Cotton production requires land and labor, and slavery was a cheap form of labor. Many landowners in the United States from the 1600s onward purchased people to be used as slaves from areas of the world like Africa to work in the cotton fields, as a way to keep operating expenses to a minimum. The extra money saved by keeping slaves instead of paid labor meant that the landowners could invest even more money into the business, and potentially make more cotton and more profits for other ventures.
Slavery was outlawed in the United States after the Civil War. This is relatively late in the century compared to British colonies, for example, such as those in the Caribbean or Canada. Cotton and slavery persisted in the confederate states in the south of the United States for longer than the northern parts of the continent, and this was one of the major differences between the two sides in the Civil War.
Plantations, which were commercial estates in the southern states, typically used African slave labor. The people in slavery were either Africans who had been kidnapped from their homes and brought over to the Americas by ship, or people who were descended from the first-generation Africans. The primary focus on people with African blood was a change from the initial forms of labor that were available to early settlers in the country.
Originally, Europeans and their descendants in America tried to make the native Americans into cheap labor, but these people were commonly familiar with the area and so were able to get away from forced labor more easily than others. Poor Europeans were the next choice, who came to live in America as indentured servants, which meant that they worked for a fixed period of years for room and board but no money. Plantation owners had to buy new indentured servants every few years, however, so when African slaves became a cheaper choice in the late 1600s due to an increased expectation of living standards for European laborers, cotton and slavery became inextricably interlinked.
Slaves were a choice of labor that made economic sense for plantation owners at that time, if not ethical sense. In comparison to the failed experiment with native American labor, newly arrived African slaves did not know the country and could not speak the language. The difference in skin color also made it tougher for a slave to escape from a plantation that combined cotton and slavery, compared to white indentured servants.
Another potentially profitable component to cotton and slavery was that the children of a woman in slavery were typically born into legal slavery. This gave the cotton plantation owners a regular supply of virtually free labor. Although cotton was a major part of the economy of the southern states, slave labor also made cash crops like tobacco and sugar more profitable than they would have been with other forms of labor.