let the cat out of the bag

"To let the cat out of the bag" means to reveal a secret or a surprise, usually by accident:

We wanted to arrange a surprise party for Jim, but his wife let the cat out of the bag

Probably this expression comes from the practice of  dishonest farmers trying to sell animals of no value (cats or others) at country fairs by putting them in a sack and pretending they were pigs. The wary customer would open the bag before buying the animal, and so the cat would be out of the bag and the secret revealed!