Smartest Farm Animal: Five Livestock Species Ranked by Research
Pigs usually top the list. Yet the research behind each livestock species is uneven, and some famous findings have not held up. This guide names the smartest farm animal based on what researchers actually tested. Then it shows what that intelligence changes in your pens and fences.
Pigs are the smartest farm animal on current evidence, followed by goats, horses, sheep, and cattle. Pigs learned a joystick video task at Purdue University. Goats recalled a puzzle box after 10 months, per Queen Mary University of London.
Smartest Farm Animals Ranked
Pigs rank first, but the gap to goats is smaller than most lists suggest. No single test measures intelligence across species. So this ranking weighs problem solving, memory, and the ability to read other animals or people. It also weighs how much testing each species has had.
Beef and dairy cattle share one entry because they are the same species. Lists that add chickens or dogs compare a different set of animals.
| Rank | Species | Strongest published evidence | Research depth |
|---|---|---|---|
| 1 | Pigs | Learned a joystick video task above chance (Purdue University, 4 pigs) | Deepest |
| 2 | Goats | Solved a two-step puzzle box and recalled it 10 months later (Queen Mary University of London, 9 of 12 goats) | Moderate |
| 3 | Horses | Read angry human faces and remembered them hours later (University of Sussex, 28 horses) | Moderate |
| 4 | Sheep | Recognized human faces from photographs, even at an angle (University of Cambridge, 8 sheep) | Narrow, strong on faces |
| 5 | Cattle | Told familiar herd mates apart in a maze (University of Cambridge, 6 heifers) | Thin |
Read the bottom of this table with care. Cattle place last mostly because few researchers have tested them. That is a gap in the research, not proof that a cow is slow. Also, most of these studies used fewer than 30 animals, so treat every rank as provisional.

Read next: How Long Are Horses Pregnant? Gestation Chart, Due Dates, and Signs
Are Pigs Smart?
Yes. Pigs learn quickly, handle tasks far outside their normal lives, and keep track of individuals. The best-known evidence comes from Purdue University. There, Candace Croney and Sarah Boysen taught two Yorkshire pigs and two Panepinto micro pigs a joystick video game. The pigs steered a cursor toward targets with their snouts and scored well above chance.
The same study also set limits. The pigs did not reach the mastery level primates reach on that task. Social contact with the handlers also strongly affected how long the pigs kept working. That matters in the barn, because a pig that responds to people also learns from every rough session.
Are Pigs the Smartest Farm Animal?
On present evidence, yes, but the margin is narrower than headlines suggest. Pigs have simply been tested more than any other livestock species. More tests produce more findings, and that pushes pigs up any ranking.
The mirror study shows the risk. In 2009, Donald Broom’s team at the University of Cambridge gave eight pigs five hours with a mirror. Seven of the eight then found a food bowl visible only in the mirror, in an average of 23 seconds. By contrast, pigs new to mirrors searched behind the glass.
However, a 2014 team at Utrecht University repeated that test with two groups of 11 piglets. They did not find the same mirror use. So the claim that pigs “understand mirrors” remains open. The joystick and learning results stand on firmer ground.
Are Pigs Clean?
Pigs are clean by choice when the pen allows it. Given room, a pig dungs well away from where it sleeps and eats. The muddy pig image comes from heat, not habit.
Pigs have few working sweat glands, per University of Missouri Extension. So they cool off by wallowing, and wet mud cools the skin as it dries. Missouri Extension also warns that heat stress can set in quickly for pigs over 100 pounds. The risk starts once temperatures pass 80 degrees F with humidity above 50 percent.
A dirty pig usually tells you something about the pen. When a hot pen has no cool, wet spot, pigs wallow in the dunging area instead. Crowding does the same, because pigs run out of room to keep the two areas apart. So the fix is shade, a sprinkler or wallow, and more space. A pig that pants hard, goes off feed, or stays down in the heat needs cooling at once and a call to your veterinarian.

How Smart Are Goats?
Goats rank second because they pair physical problem solving with reading people. Researchers at Queen Mary University of London gave 12 goats a two-step puzzle box. Each goat had to pull a lever with its mouth, then lift it to release food. Nine learned the task, on average within 12 trials. Ten months later, all nine solved it again in under two minutes.
A later Queen Mary study added a social layer. When 34 goats faced a box they could not open, they looked toward a nearby person. They looked sooner, more often, and for longer when that person faced them rather than turned away. Dogs and horses do the same thing.
That mix explains the escape artist reputation. A goat learns a latch, remembers it, and checks who is watching. So gate latches need a second step, such as a snap clip. Fencing also has to stop climbing as well as pushing, and how tall a goat fence needs to be depends on that.

How Smart Are Horses?
Horses rank third, and their strength is social. University of Sussex researchers showed 28 horses photos of happy and angry human faces. Angry faces raised heart rate faster. The horses also turned to view those faces with the left eye, which feeds the brain hemisphere that processes threats.
A 2018 Sussex study went further. Horses saw a photo of a person looking angry or happy. Hours later, they met that same person, now wearing a neutral expression. Even so, their gaze showed they still viewed the person who had looked angry more negatively.
In practice, a horse reads your face before you touch the halter. Calm, consistent handling pays off over a horse’s long lifespan, which gives it many years to build on what each handler teaches.
How Smart Are Sheep?
Sheep are far sharper than their reputation, especially with faces. Researchers in Cambridge, England, reported in 2001 that sheep remember about 50 other sheep faces for more than two years.
In 2017, a University of Cambridge team trained eight sheep to recognize four celebrities from photographs. The sheep picked the learned face eight times out of ten. They also knew those faces when tilted, a skill the authors say had been shown only in humans. Several sheep even picked out their handler’s photo with no training on that face.
So why fourth? The evidence is narrow. It centers on faces, with far less on problem solving. That is a research gap, so the rank could move.
For your flock, the takeaway is memory. Sheep remember who handled them and where stress happened. Where you can, keep handlers, groups, and working pens consistent.

Are Cows Smart?
Yes, though cattle are the least tested of the five. At the University of Cambridge, Kristin Hagen and Donald Broom put six heifers through a Y-shaped maze. Each heifer had to find the arm where a particular familiar herd mate stood. All six learned the task with at least one pair of herd mates, choosing correctly in 19 of 20 consecutive trials.
A second Cambridge study asked whether learning itself excites cattle. Heifers that opened a gate by solving a task were compared with heifers given the same feed without solving anything. The learners showed some signs of excitement, measured by heart rate and how lively they moved toward the feed. Still, the authors called that evidence inconclusive.
For beef and dairy herds, the useful point is recognition. Cattle tell individuals apart, so a herd can link a handler, chute, or alley with a bad experience. That is a strong case for low-stress handling at weaning, at the chute, and around calving.
What Livestock Intelligence Changes on Your Operation
Smart livestock are easier to train and harder to contain. Each species turns its strongest skill on the weak spots in your setup, so plan around it.
| Species | What the research shows | What to plan for |
|---|---|---|
| Pigs | Learn tasks fast and respond to handler contact | Rooting material, enrichment, and latches a snout cannot lift |
| Goats | Solve two-step problems and recall them for months | Two-step gate latches and fences built against climbing |
| Horses | Read and remember human expressions | Calm, consistent handlers |
| Sheep | Recognize individual faces for years | Stable handlers, groups, and pens |
| Cattle | Tell individuals apart | Low-stress chute and alley routines |
Pigs need a job for their snouts. In a bare pen, bored pigs turn that drive on fixtures and pen mates. Rooting material gives it an outlet, and what pigs eat and how they forage covers the feeding side.
Memory also adds up over time. A sow kept for several litters, or a pet pig kept for its full natural lifespan, carries every handling lesson forward. For gates, latches, and fence lines across all six species, the housing and fencing guides go into detail.
Frequently Asked Questions
Are pigs smarter than dogs?
No study shows pigs are smarter than dogs overall, because the two are rarely given the same test. Purdue’s joystick study used a task built for primates, and the pigs fell short of primate mastery.
Why does my pig roll in mud?
Your pig is cooling off, because pigs have few working sweat glands. Wet mud cools the skin as it dries, so a hot pig without shade or a sprinkler will dig its own wallow.
Do sheep recognize their owners?
Yes, sheep recognize familiar people by their faces. In a 2017 University of Cambridge study, some sheep picked their handler’s photo with no training on it. That face was already stored in memory.
Why do goats keep escaping?
Goats learn and remember how latches and gaps work. Queen Mary University of London found goats recalled a two-step puzzle 10 months later, so one successful escape tends to be repeated.
Are cows smarter than horses?
Nobody has tested the two head to head, so there is no firm answer. Horses have more published evidence for reading people, while cattle research is thin and centers on recognizing herd mates.
Do cows remember people?
Cattle tell familiar herd mates apart, per University of Cambridge maze research. Direct tests on recognizing people are scarce, so the safe course is to assume a cow remembers rough handling.
Putting This Into Practice
Pigs lead on the evidence, goats and horses follow closely, and sheep and cattle are undertested rather than slow. Treat every rank as provisional, since most studies used fewer than 30 animals. On your place, plan latches, fences, and handling around what each species can learn and remember.
