The surprising news was revealed during Sunday’s season finale of Keeping Up with the Kardashians.
While the 33-year-old was visiting San Francisco with her sisters Kim Kardashian West and Kourtney Kardashian, she got a call from their sister Kylie Jenner, who had learned the baby’s sex from Khloé’s doctor.
Want all the latest pregnancy and birth announcements, plus celebrity mom blogs? Click here to get those and more in the PEOPLE Babies newsletter.
“Is she lying or serious?” Khloé asked Kim, 37, before explaining that she really felt like she was pregnant with a boy.
Overhearing the news from another room, Kourtney walked up to her sisters and revealed she had also been taken by surprise by the baby’s sex. “I’m shocked,” the 38-year-old remarked.
But although she may have initially wanted to have a boy, on Sunday, the Revenge Body star clarified on Twitter that she’s thrilled to become the mother to a little girl.
“God gives us what we need! His timing is never wrong! my hormones were IN RARE FORM for that news,” she tweeted.
“I am now so excited my daughter will have forever best friends with Chicago and Stormi!!” Khloé added of her newborn nieces. “God is great!!! Thank you Lord for our princess.”