The attacking midfielder had been linked with a number of Premier League clubs over the summer but has now pledged his long-term future to Malky Mackay's side.
The 27-year-old has played over 250 games in all competitions for the Bluebirds since joining from Aston Villa in 2007.
Mackay told the club's official website: "We're absolutely delighted that Peter has committed himself to the club for the longer term following a couple of top-flight clubs coming in for him.
"I had a good conversation with him and he's decided to commit his future with us right here.
"Despite strong Premier League interest, he sees what we are trying to build here and he wants to be part of that."
- Malky Mackay
- Premier League
- Aston Villa