It's Roman slang: "Noli equi dentes inspicere donati". For example, you can find it in St. Jerome's Commentary on the Epistle to the Ephesians, written in the 5th century.
You look in a horse's mouth to determine its age and/or health. So if someone gives you a horse, and you look in it's mouth, it's like looking for a price tag. It's rude!
Lucius: I bought you this tunic in Thebes for your birthday.
Quintus: Thanks dude. Hey, look, the seam has really cheap thread.
Lucius: Noli equi dentes inspicere donati.
Lucius: It's Latin. Don't look a gift horse in the mouth.
Quintus. Oh yah, right. Mea culpa.
to be critical of a present or gift
Despite thought put into the gift, he decided to look a gift horse in the mouth and commented on the cheapness of the gift
A gift horse "lays" gifts, much like the golden goose.
You don't want to know what it eats.
The modern interpretation is corrupted from the original 'given,' not 'gifted.'
To not examine a gift is to ignore subtle compliments or insults, and can be dangerous. Such was the case in the Trojan Horse.
"This roast is delicious. Do you want to go to the slaughterhouse after?" mused Betty.
"Don't look a gift horse in the mouth." quipped Martha.
"My girlfriend's taking me out, but I think she got the money from whoring at the truck stop," said Jose.
"Don't look a gift horse in the mouth," cautioned Miguel.
(On a chairlift) "Isn't it sad there are no tee pees or buffalo here?" wondered Jane.
"Don't look a gift horse in the mouth," snapped Stacie.