Liz Simons, who has been trying to have a baby with her husband, Dave, for 12 years, said she is due to give birth in December.
The couple, of Bramley, Leeds, were left traumatised and heartbroken last year, after Mrs Simons' friend, Shirley Farrell, gave them her seventh child, Thomas, only to take him back four months later.
Mrs Simons, 31, had already unsuccessfully tried fertility treatment several times, and she was told earlier this year that she would never be able to conceive naturally.
When she discovered she was pregnant, she was planning a final course of IVF treatment in a last desperate bid to have a child.
She said: "When I went for the results I thought they were joking, and then I started crying.
"We were in total shock at first - we just couldn't believe it. Now we are just so happy - it's fantastic news."
Mrs Farrell, 36, of Drighlington, Leeds, took back baby Thomas - who was born in July last year - because she said she had bonded with him.
She is now pregnant with her eighth child and said she was pleased that Mr aqnd Mrs Simons were finally expecting their own baby.
Mrs Simons added: "I think of all the trouble and can now see there was a reason for it.
"No-one can take away this baby. It's a fairytale ending - a real miracle."Reuse content