The 5-foot square is the standard measurement in every edition of D&D published by Wizards of the Coast, starting with 3rd Edition in 2000.
In editions prior to WotC taking over publication, there was no standard. Mapping of constructed areas was typically in 10-foot squares, and the ubiquitous gridded battle mat was almost unknown to D&D players. The 5-foot square and gridded combat made an appearance in the TSR-published Player's Option: Combat & Tactics in 1995, and this might have influenced later 3e design, but it wasn't widely adopted and can't be said to have made the 5-foot square a standard.
Prior to moving to a visually-focused, grid-based design, D&D editions typically simply gave limits to how many combatants could fight abreast in a given corridor width. The most common rule across editions (I believe) is that three combatants can fight side-by-side in a 10-foot corridor. This 3-foot-wide clearance wasn't intended to describe how much space a character occupied or controlled in combat though – it was exactly and only a statement about how close friendly forces could pack together while still being able to fight.
Because earlier editions had a heavy dose of simulationism, abstractions were either avoided and whatever non-standard measurement that was appropriate was given directly, or the abstractions were at a more more granular level than anything that could be consistently gridded. Measurements were also were very context-dependent. In other circumstances than combat, the space occupied by characters was described differently – for example, when squeezing through narrow caves, the Dungeoneer's Survival Guide (1986) gives a table of minimum tunnel widths by race, listing humans as requiring at least 2 feet of width to pass and elves needing 1½ feet, as well as variations in minimum height clearance.
As a general rule, TSR editions of D&D (and games based on them) can be assumed to use continuous real-world measurement systems for everything, while WotC editions can be assumed to use a discrete 5-foot square. This continuous/discrete paradigm difference is fairly fundamental in their respective designs, with the measurement style coming first, with rules built on top and referring back to the measurement paradigm. For example, D&D 3e and later mostly bases movement rules on the 5-foot square and on manipulations of whole or part squares, while 2e and earlier deal in yards, feet, and inches and modifications to those continuous measurements.