The 28-year old Scotland international initially joined the Bluebirds from Norwich City in May 2009 but has now signed on until the summer of 2018.
The Glasgow-born Marshall, who kicked off his career at Celtic, was thrilled to commit himself to the Cardiff cause.
"I'm delighted to have committed my future to Cardiff City," said Marshall.
"I've had a fantastic four-and-a-half years here already.
"It's a privilege to be part of what we're trying to achieve and the fans have been brilliant to me from day one.
"We've a lot of hard work left to do this season, but we're a confident group and have plenty of ability and belief."
For breaking stories and all the great banter like us on Facebook: facebook.com/tribalfootball