Can an employer withdraw a job offer if it subsequently discovers that the successful candidate is pregnant?

No, withdrawing a job offer because a potential employee is pregnant constitutes pregnancy and maternity discrimination contrary to the Equality Act 2010. This is the case even if the position for which they are applying is for a fixed term and they will not be able to see the term through, for example if the position is to cover someone else's maternity leave.

There is no obligation on a job applicant to disclose their pregnancy to a potential employer at the interview, or before accepting the post.

Where the successful candidate has already accepted the job offer, withdrawing it at this stage would amount not only to pregnancy and maternity discrimination, but also to a breach of contract, and could give rise to a claim for automatic unfair dismissal (employees do not require any qualifying period of service to claim unfair dismissal where the reason for dismissal is pregnancy).