וּמָע֤וּךְ וְכָתוּת֙ וְנָת֣וּק וְכָר֔וּת לֹ֥א תַקְרִ֖יבוּ לַֽיהֹוָ֑ה וּֽבְאַרְצְכֶ֖ם לֹ֥א תַעֲשֽׂוּ׃
-(Leviticus.22.24)
The 361st prohibition is that we are forbidden from damaging the reproductive organs of any male, including all species of animals and humans.
The use of contraception touches upon several possible prohibitions, including 1) Zera Levatala, 2) Transgressing Peru Urevu or Liareiv, and 3) Prohibition of castration.
This is dependent on the type of contraceptive being used, the number of children one already has, the medical and mental state of the mother, and the reason why a contraceptive is desired.
Aside from this possible letter of the law Halachic impediment, there are also Hashkafic reasons to abstain from using a contraceptive even when there is room to be lenient according to Halacha, as it is well known that the Gedolei Yisrael urged couples to have large families and avoid family planning.
Practically, the general approach today amongst accepted Rabbanim is only to permit the use of a contraceptive if there is a natural and legitimate physical or mental health reason applicable for doing so or if it may affect the nursing of a newborn child.
Every couple who is contemplating using a contraceptive is to bring up the matter to a qualified Rav, explain to him the reasons for why a contraceptive is being considered, and if deemed valid, then ask his Halachic direction as to which type of contraceptive may be used and is recommended to be used, in the case of their predicament.
Sources: Family Planning - Contraceptives and Birth Control in Jewish Law (The Shulchan Aruch Harav) - based on the Summary by Rabbi Yaakov Goldstein)