It is unclear exactly how old the Doctor was when he regenerated at the end of "The Parting of the Ways".

The Tenth Doctor gave his age as 903 in "Voyage of the Damned". It is known that he had been in this body for a while, and the Ninth Doctor had said that he was 900 in "Aliens of London".

Shortly before he regenerated the Tenth Doctor said that he was 906("The End of Time").

In real life the actor David Tennant was 34 when he first appeared as the Doctor, and 38 at the end of "The End of Time" Part 2.