Burj Khalifa in Dubai is the tallest skyscraper in the world, rising 2,717 feet. That’s twice as high as the Empire State Building. How can buildings stretch so high without toppling over?

Until the late 1800s, most urban buildings didn’t peak over 10 stories. Getting much taller was physically impossible with the available construction materials. The higher you build with brick and mortar, the thicker the lower walls have to be. The base of a 70-story brick building would have been so thick that there wouldn’t be any room for a lobby.

That all changed as modern steel became more common. Today, all skyscrapers have a skeleton—a steel frame of vertical steel columns and horizontal I-beams. This skeleton (called the superstructure) transfers all of the building’s weight to the vertical columns, which spread the weighty force of gravity down to the building’s foundation.

The foundation, or substructure, usually stretches down all the way to bedrock. Builders may dig a pit hundreds of feet down to solid rock, where a platform of concrete is laid. Holes called footings are drilled deep into the bedrock, and steel beams are secured inside those holes to anchor the building above.

Most skyscrapers may look square and boxy, but they’re actually circular tubes with cantilevered corners. Ever since the 1960s, skyscrapers over 40 stories have been built with a tubular frame—an engineering technique that saves money and frees up floor space because it requires fewer columns inside. (Chicago’s Willis Tower—formerly the Sears Tower—is actually a bundle of nine tubes.) In the middle of tower, a central concrete core contains elevator shafts, stairwells, and the building’s mechanical guts.

That concrete core is especially important on gusty days, allowing most tall buildings to safely sway like a tree in the breeze. Some buildings battle the wind with tuned mass dampers, oil hydraulic systems that hold a 300 to 400-ton concrete weight near the top floor. A computer system monitors the wind and moves the weight, shifting the building’s load from side to side.