Be aware that currently such contracts are not legally binding in the UK - that could change in the future.
But having a contract will help prove your intentions at the time it was made, but don't rely on it too much.
It concerns me that you have no qualms about having a baby with a man you are worried about having a mortgage with.
Maybe you simply aren't ready for such a major commitment.
Life is a gamble, sadly. Look at all your options. You could, for example, move in with him and rent your house out - or sell the house and put the profits in trust for your son.