Leviticus 27:10

He shall not substitute it or exchange it, good for bad or bad for good; and if he at all exchanges animal for animal, then both it and the one exchanged for it shall be holy.

Surrounding context

27:9 "If it is an animal that men may bring as an offering to the LORD, all that anyone gives to the LORD shall be holy.

27:10 He shall not substitute it or exchange it, good for bad or bad for good; and if he at all exchanges animal for animal, then both it and the one exchanged for it shall be holy.

27:11 If it is an unclean animal which they do not offer as a sacrifice to the LORD, then he shall present the animal before the priest;

Translation and sources