In 1905, Lebesgue gave a "proof" of the following theorem:
If $f:\mathbb{R}^2\to\mathbb{R}$ is a Baire function such that for every x, there is a unique y such that f(x,y)=0, then the thus implicitly defined function is Baire.
He made use of the "trivial fact" that the projection of a Borel set is a Borel set. This turns out to be wrong, but the result is still true. Souslin spotted the mistake, and named continuous images of Borel sets analytic sets. So a mistake of Lebesgue lead led to the rich theory of analytic sets. Lebesgue seemingly enjoyed this fact and mentioned it in the foreword to a book of Souslins's teacher Lusin.

