Steve Simonsen put the hosts behind after just four minutes, but the Dens Park outfit equalised through Ryan Conroy just five minutes later.
A Lee Johnson strike followed by a Sammy Clingan shot made it three for Kilmarnock, but despite a second goal for Dundee from Mark Stewart, it was not enough to prevent defeat for the recently-relegated side.
In spite of the scoreline, Dens' assistant boss Farningham praised his players for their approach.
"I thought we did well in the first half and were slightly the better side. To lose the game was disappointing," he said.
"We had been on such a good run and maybe last week knocked the stuffing out of the players a wee bit. There was a bit of slackness around the team today, which had been missing in the previous games.
"We can't fault the lads. They've given their all over the last few months and at 3-1 down they could have chucked in the towel but they kept on going and we could have got something out of the game.
"But they are disappointed because they wanted to win our last home game of the season in front of our own fans."