In the final episode of GOT's season 6, Grand Maester Pycelle is killed by Qyburn's little birds in a very cruel way. But I never quite understood why Cersei wanted to get rid of him. In the end he was always a loyal servant of the Lannisters as he states here:or at least a nonetheless loyal opportunist counselor for whoever sat on the iron throne. He didn't bother Cersei before, so why her change of mind now? Also, who will be Grand Maester now in Cersei's cabinet? Qyburn would be a candidate, but I take it he will be Hand now.
She doesn't need Pycelle.
Pycelle was the only potential dissenting voice. Naturally he couldn't do anything about Cersei being in power and it's unlikely that he would have gone to much effort to undermine her. But Cersei doesn't need him. And Pycelle doesn't like Qyburn, whom neither she nor Qyburn are fond of.
Most of all, Cersei is now Cersei without her children, so she has absolutely nothing holding back her ruthless cruelty. Since she has Qyburn who is far more loyal and helpful, why not remove Pycelle?
It was clear with the various interactions between Cersei and Pycelle that she didn't trust him completely. She obviously wouldn't want anyone to come between her and the Iron Throne and hence she joined hands with Qyburn, whom she trusts, to plan and murder Grand Maester Pycelle.
If we go by the book, Varys is the one who kills Pycelle, but in the TV Series the killers are Cersei and Qyburn (Qyburn's little birds).
Pycelle would have probably known about the reserves of wildfire and Cersei left no stone unturned to murder all those who could threaten her reach to being the Queen of Westeros. This could explain why she did this to Pycelle.
"In the end he was always a loyal servant of the Lannisters..."
I disagree. Pycelle never showed absolute loyalty to the Lannisters. This was made abundantly clear all the way back at Joffrey's wedding. Cersei tells Pycelle to give the leftover wedding food which Queen Margery decreed was for the poor, to the dogs. Pycelle promptly tries to refuse since it would undermine the new queen's orders (Cersei then tells him that she is the queen and that she'll feed him to the dogs if he doesn't.)
Margery had literally just become Queen, and Pycelle was already shifting his loyalties. Pycelle is a pragmatist, not a loyalist.
It's worth noting that Pycelle also "faithfully" served the Targaryen dynasty for decades, until they fell out of power, at which point he betrayed them. Tommen was the 6th king Pycelle served under. He never would've survived so many power shifts if his loyalties weren't flexible.
In Cersei's eyes, Pycelle was a weed that needed to be pulled. And despite her frequent lack of foresight, she clearly understands the cardinal rule of the Game of Thrones: dead men can't plot against you.