The background of the custom of Kaparos:
It is customary in these provinces [of Ashkenazi Jewry] to take and slaughter a chicken, which is called a Gever, for atonement on Erev Yom Kippur. One takes a male chicken for each male family member and a female chicken for each female family member, and waves the chicken around the head upon pronouncing Zeh Chalifasi.
Background and other opinions:
The custom of Kaparos dates back hundreds of years to at least the times of the Geonim. [Rama 605:1 “Some of the Geonim wrote regarding this custom and it is recorded by many of the Achronim and so is the custom of our communities”] Rav Haiy Gaon testified that this was the custom in his days. [Rashba 395] It was mainly an Ashkenazi custom that later spread to certain Sefaradic communities. [See Rashba ibid] The Rashba ibid writes that although he abolished this custom from his community due to it resembling the act of the Emorites nevertheless he testifies that this is an accepted custom in the Ashkenazi communities. The Orchos Chaim, in name of the Ramban, writes against this custom. The Michaber in 605:1 rules accordingly that the custom of Kaparos is to be nullified. [In some earlier versions of the Shulchan Aruch, the title page reads that the custom is a custom of nonsense “Minhag Shtus Hu.” Practically, however, many have negated this title page from having been authored by the Michaber ibid, and hence in most versions of the Shulchan Aruch, and all current versions, it is omitted. See Shemesh Tzedakah 23; Answer of Shevet Halevi, Rav Shlomo Amar, and other Rabbanim to publisher of Shulchan Aruch Hashaleim Machon Yerushalayim that it should be omitted] The Rama ibid defends the custom saying it is based on the Geonim of previous generations and thus is forbidden to be swerved from. The Alter Rebbe records this custom and does not make any mention of the opinion of the Michaber. Practically, even amongst the Sephardim the custom spread to do Kaparos [Kaf Hachaim 605:8] The Arizal himself was very careful regarding this custom. [Piskeiy Teshuvos 605:1] The Maharal in Nesivos Olam, Nesiv Habitachon, writes there is a complete proof for this custom from the Talmud in Brachos. [Shaar Hakolel 42:1] A similar custom to Kaparos [however not with a chicken, and not on Erev Yom Kippur] is brought in Rashi Shabbos 81b.
 Admur 605:1; Siddur Admur; Rama 605:1 in name of Geonim; Rav Haiy Gaon
 Siddur Admur based on Yuma 20b; Rosh Yuma 8:23 “Since its name is Gever it is able to atone for man which is called Gever”
 The reason: We slaughter the chicken in order to subdue the severities, and we remove it’s blood in order to sweeten it. It is called a Kaparah similar to the scapegoat that is thrown off the cliff on Yom Kippur. [Siddur Admur; Siddur Arizal; Peri Eitz Chaim; Shelah 235b; See Shaar Hakolel 44:1]