The 33-year-old, who has made 48 appearances this term, took up the role when Dean Saunders left for Wolves in early January and has been a revelation, with Rovers on the brink of winning promotion in League One.
"I'm delighted, it's been a good season for me both on the field and off," he said.
"I felt at home as soon as I came here and when the talks started in January about extending my deal I was very forthcoming in my desire to stay.
"I was happy with the process and glad that it has been done so I can go away in summer knowing I am secure for the next two years.
"The chance to develop off the field had an influence as I have made it known that coaching and managing is where I want to move towards when my playing career ends eventually.
"I would like to thank the owners for giving me the chance to take up this dual role at the club.
"The experience I have gained since January has been invaluable to me and cemented what I want to do in the future.
"The decision was easy for me and was made quickly, as I have enjoyed the extra responsibility but also I am at a good football club with a good group of players who can move this club forward."