Shulchan Aruch
The source for this practice is the ruling of the Moses Isserles in the Shulchan Aruch, Yoreh De'ah 265:12: