Gyan Singh bagged 4,81,398 votes while his Congress rival polled 4,21,015 ballots, an election official said.
However, the BJP's victory margin in Shahdol has been substantially reduced from 2,41,301 in the 2014 general election to 60,383 this year.
Madhya Pradesh Chief Minister Shivraj Singh Chouhan had frequented Shahdol to ensure that BJP retains the seat as he did not want to give any chance to his rivals to attack him, given that his party had failed to retain the Ratlam-Jhabua Lok Sabha seat by-poll in November last year.
Congress had fielded Himadri Singh, daughter of former Union Minister Dalbir Singh and ex-MP Rajesh Nandini Singh from Shahdol Lok Sabha seat.
A total of 17 candidates were in fray for the Shahdol by-poll.
The Shahdol LS seat by-election was necessitated due to death of sitting BJP MP Dalpat Singh Paraste.