New Delhi (CNN)India's ruling Bharatiya Janata Party (BJP) has retained power in Prime Minister Narendra Modi's home state of Gujarat -- but only by a whisker.
The BJP won 99 of the 182 assembly seats available in the key state election, with the main opposition Congress Party claiming 77 seats, according to election authorities.
In 2012, the BJP won 115 seats while Congress secured 61.
"This is a positive message for the Congress. They have been able to increase their vote share, their seat tally has gone up and the notion of invincibility of the BJP, that no party can defeat them, that has not broken but at least been punctured," Sanjay Kumar, Director of the Center for the Study of Developing Societies, told CNN.
The BJP has controlled Gujarat since 1995, with Modi ruling the western Indian state for more than a decade before becoming India's leader.
In a tweet, Modi thanked voters and vowed to continue to serve them.
"I bow to the people of Gujarat and Himachal Pradesh for their affection and trust in BJP. I assure them that we will leave no stone unturned in furthering the development journey of these states and serve the people tirelessly," he said.
Monday's result marks the BJP's worst performance at a state election in Gujarat in more than two decades, with analysts pointing to widespread dissatisfaction over Modi's recent economic policies as a primary reason for the drop in poll numbers.
"The BJP has come through, but it's definitely the opposition that's going to see this as a small victory," Neelanjan Sircar, Senior Fellow at the Delhi-based Center for Public Policy Research, told CNN. "Modi came in with his motto, 'I am development, I am Gujarat,' and they claimed they were going to win 150 seats. That was just a few months ago so it shows you the ground that was made up by the opposition."
Modi, who swept to office in 2014 with promises to boost income levels, has seen his record challenged in recent months as a slowdown in the country's economy begins to bite.
Although growth in the most recent quarter recovered to 6.3% after slumping to a three-year low, it remains below levels seen last year. This leaves India trailing China, which grew at 6.8% over the same period.
Many blame the slowdown on two of Modi's signature policies: last year's sudden ban on high-value currency notes, and the introduction, earlier this year, of a new national goods and services tax to replace the patchwork of local levies. Many small businesses in states like Gujarat have struggled to adapt to the new systems, fueling anger against the BJP.
Meanwhile, in the northern state of Himachal Pradesh, which held assembly elections on November 9, a total of 68 seats were up for grabs. The BJP won 44 seats while the opposition Congress secured 21.