In many proliferating epithelia, cells present a polygonal shape that results from tensile forces of the cytoskeletal cortex and from the packing geometry set by the cell cycle1,2. In the larval Drosophila epidermis, two cell populations, histoblasts and larval epithelial cells, compete for space as they grow on a limited body surface. They do so in the absence of cell divisions. Here we show that histoblasts, which are initially polygonal, undergo a dramatic morphological transition in the course of larval development. Histoblasts change from a tensed network configuration, with straight cell outlines at the level of adherens junctions, to a highly folded morphology. The apical surface of histoblasts shrinks while their growing adherens junctions fold. Volume increase of growing histoblasts is accommodated basally, compensating for the shrinking apical area. The folded geometry of apical junctions is reminiscent of elastic buckling. In accordance, we show that folding of junctions results from an imbalance between the growth of the junctions and the increasing crowding of the epidermis. The process also correlates with a change in the junctional acto-myosin cortex and possibly mechanical properties. We propose a model in which crowding of the epidermis imposes a compressive load on the growing junctions which induces their buckling. Buckling effectively compacts histoblasts at their apical plane and may serve to avoid physical harm to these adult epidermis precursors during larval life. Our work also indicates that in growing non-dividing cells, compressive forces, instead of tension, may drive cell morphology.