She then sang one of her biggest hits, "You've Got a Friend," trading verses with Jessie Mueller, the actress that plays her in the show.
King was reluctant until Thursday night to see the musical because it tells of a painful time in her life.
She said in a statement that it was an honor to see the show for the first time and that she was thrilled to help the cast raise $30,000 for Broadway Cares/Equity Fights AIDS.
King says "Jessie Mueller and company are fantastic, and it was so joyous to be there. I couldn't be more proud."
Follow John Carucci on Twitter at http://www.twitter.com/jacarucci