Sonata form is an evolution of the binary form. We find a very good example in the first movement of Haydn's Divertimento Hob XVI : 8 (often titled Sonata).
In this movement, what would be section A of a binary form is the exposition. Its first phrase - in the main key - is the first part and the second phrase - in the dominant key - is the second section.
The development begins in section B. After only 10 measures, we find the recapitulation. The second phrase is now in the main key.
The repetition of the development and the recapitulation will later be discarded, yet we will still find it in Mozart's sonatas.