She's made no secret of how difficult her previous two pregnancies have been.

And now Kim Kardashian has revealed she will be having a last ditch surgery in order to have a third child.

In a preview for an upcoming episode of her E! reality series, the 36-year-old announced at the dinner table that she would be undergoing surgery to repair her uterus.

Scroll down for video

'I'm going to try to have one more baby': Kim Kardashian has revealed she will be having a last ditch surgery in order to have a third child

Over dinner, Kris Jenner was talking about throwing a baby shower for friend Joyce Bonelli when Kim brought the topic up.

'Should I try to change my surgery?' she asked. 'I have to go in and prepare my uterus because I decided I'm going to try to have one more baby.'

'So what surgery are you having?' Khloe asked.

Kim explained: 'I have to have a surgery on my uterus, to kind of repair this hole. So they need to like, clean that out, and there's like scar tissue. It'll also be a really high-risk pregnancy just I would be able to get pregnant.'

Big news: 'Should I try to change my surgery?' she asked over dinner. 'I have to go in and prepare my uterus because I decided I'm going to try to have one more baby.'

What!? Khloe seemed stunned her sister was seriously considering going through it, and asked: 'So why do you want to do it again?'

Baby on the way: Over dinner, Kris Jenner was talking about throwing a baby shower for friend Joyce Bonelli when Kim brought the topic up

Risky: The reality star explained, 'It'll also be a really high-risk pregnancy just I would be able to get pregnant'

Khloe seemed stunned her sister was seriously considering going through it, and asked: 'So why do you want to do it again?'

In her one-on-one interview, Kim explained she didn't want to regret looking back and thinking she could have done more to give her children siblings.

'Having more kids is definitely gonna be a struggle. I've gone through so much with really bad deliveries that the doctors don't think it's safe for me to conceive again myself.

All ears: Kourtney Kardashian listened intently during her sister's announcement

Difficult: A flashback showed a doctor recounting what a difficult time Kim has had with pregnancy

'This surgery is really the one last thing I can try. I want my kids to have siblings, and I want to know that I did everything that I could to make this happen.'

Kim suffered from preeclampsia when she was pregnant with daughter North, age three.

The reality star's son Saint was also in the breech position during her second pregnancy, and she underwent a procedure to have him turned into the right position to avoid having a C-section.

Listening close: Kylie and Khloe gave their sister their undivided attention

Family matters: The sisters were gathered around dinner when Kim made the announcement

Kim recounted the agony of the procedure when describing it on her app and website kimkardashianwest.com: 'They don't give you any pain medication, and let me tell you: This was soooooo painful. Probably more painful than childbirth. BUT it worked!!!'

She wrote: 'They gave me an IV with medication to relax my uterus, and then three doctors attempted to work together to turn the baby.

'There was a risk that my water might break or the baby's heart rate could drop—in which case, an emergency C-section would then take place. I went in with my sisters and my husband. I was prepared for it all!'

Sundays at 9pm on E! Available first in the UK & Ireland Mondays on hayu

Rise and shine: Kim shared a photo of herself eating a bowl of oatmeal on Thursday