I’d never really thought about it, but even back in medieval times when paper was being made by hand there were standard sheet sizes. These were no doubt less formal and rigid than today’s, but sheet sizes turn out to have grouped around certain popular sizes which played the role of standard sizes. After all you had to have moulds and deckles: these were reused time and again. If your customers got used to paper in these sizes, neighboring paper makers would tend to conform to the same or closely similar sizes.
The Schoenberg Institute for Manuscript Studies at the University of Pennsylvania has created the Needham Calculator, a tool for calculating sheet size of manuscripts. Enter a few details and bang, bang, there are the dimensions of the original sheet. The Penn Libraries blog describes the tool and its rationale.