SYSTEM ONLINEOPERATOR: INVALID
Start Here — Ready. Set. Make.
← ALL POSTS
FastenersOctober 10, 2026· JP T

Why are nuts and bolts hexagonal? (and when square wins)

Why are nuts hexagonal instead of square? Wrench swing, rounded corners, and a little geometry — plus why square nuts are secretly better for 3D prints.

Four zinc-plated hex nuts stacked in a column against a black background
Photo: Nic Wood / Pexels

You're lying on your back under the bench, wrench on a nut you can barely see. You get about a sixth of a turn before the handle hits the frame. Pull it off, flip it, re-seat, another little nudge.

That's why nuts and bolt heads are hexagonal.

Six sides is the sweet spot. Enough flats that a wrench can re-grab in a tight space, few enough that each corner is big and beefy and doesn't round off the first time you lean on it. And you lose less metal making a hex than a square. That's the short answer.

The long answer is more fun, and it ends with a reason to use square nuts in your 3D prints.

Square nuts came first

For most of history, nuts were square.

Before machines, threads and flats were cut by hand — filed and chipped, one at a time. Four flat faces at right angles is just easier to file than six faces at 120°. Nobody wrote down "we picked square because hexes are a pain," but if you've ever tried to file a clean hexagon by hand, you get it.

Hex took over once machines made six flats cheap.

There's a great story from 1829. James Nasmyth, then working for Henry Maudslay (the guy behind the screw-cutting lathe — the full history of nuts and bolts is here), had to make around 300 tiny steel nuts and bolts for an engine model. Every one needed exact hex flats. Filing them by hand was, in his words, "practically impossible."

So he built a little machine. A rotating cutter, an indexing plate that clicked the part around one-sixth of a turn at a time. Six cuts, perfect hex, next.

Nasmyth didn't invent the hex nut — they were already around. He just made it painless. Which is how most things win.

The wrench math

Here's the part every "why are nuts hexagonal" article gets a little wrong.

  • A hex nut with a 6-point socket or box wrench re-grabs every 60°. A square nut needs 90°. In a tight spot, that difference is a damn big deal.
  • An open-end wrench has its jaws angled about 15° off the handle. Flip it over and you've shifted the angle — so you can work a hex in about a 30° swing by flipping back and forth. That's the trick you were doing under the bench.
  • A 12-point socket re-grabs every 30° too. But it only touches the corners, and 12-points have been known to round off 6-point bolts. Use the 6-point when it fits.

So why not go further? Eight sides? Twelve?

Because the more sides you add, the more the shape turns into a circle, and the smaller each corner gets. Small corners round off. Then you've got a nice smooth cylinder that no wrench on Earth can grip, and you're drilling the damn thing out. Ask me how I know.

More sides = easier to grab, easier to strip. Six is where those two lines cross.

The round-bar math

There's also a material argument, and it's just geometry.

Take a round bar and cut the biggest hexagon you can out of it. You keep about 83% of the material. Cut the biggest square instead and you keep about 64%.

The hex also comes out wider across the flats — 0.866× the bar diameter, versus 0.707× for a square. Same bar, bigger wrench size, less waste. (Most nuts today are forged and then tapped, not cut from bar, but the geometry still explains why hex feels "efficient.")

Pentagons are the troll option

Ever looked closely at a fire hydrant?

The operating nut on a lot of US hydrants is a pentagon — five sides, about 1½" from a point to the opposite flat. Fire Engineering describes it as a design that makes "unauthorized use without the proper wrench difficult."

Here's why it works: a pentagon has no parallel sides. Every flat is across from a point. A regular open-end wrench or an adjustable crescent needs two parallel flats to grip, so it just slides around. You need the special hydrant wrench.

It's anti-theft by geometry. I think that's beautiful.

Square nuts never actually left

Square nuts are still everywhere, quietly being better at a few things.

  • More bearing surface. A square nut has more area pressing on the part than a hex of the same size, which means more grip and more resistance to loosening.
  • Hard to round off. Those 90° corners are chunky.
  • They don't spin in a slot. Slide one into a channel and it's locked. That's why you see them in carriage bolts, unistrut, and…

…your 3D printer.

Prusa printers use thin M3 square nuts (DIN 562, 5.5 × 5.5 × 1.8 mm) that slide sideways into slots in the printed parts. The nut can't rotate, it can't fall out the front, and you can tighten the screw without ever touching the nut. Prusa's own assembly tip when one won't seat: thread a long screw in from the other side and pull the nut into its pocket.

The rest of the weird family

Quick tour, because these all exist for a reason:

  • 12-point bolts — aerospace uses them for high-strength, high-fatigue joints. The FAA's maintenance guide lists them for exactly that. Bolt makers pitch the smaller head for the same torque, which helps in cramped or counterbored spots.
  • Castle nuts — slots across the top so a cotter pin can go through the bolt. Can't back off, period.
  • Wing nuts — for anything you tighten by hand and loosen often. Lamp shades. Drum hardware. Jigs.
  • Flange nuts — a built-in washer. Spreads the load on soft stuff.
  • T-nuts — pressed into the back of wood so you can bolt into it from the front. Every pegboard-and-jig wall's best friend.

What this means for your prints

If you're designing a nut trap into a 3D print, the shape matters:

  • Hex pockets are great for dropping a nut in from the top. Orient a flat parallel to the bed and the walls print clean.
  • Square slots are great from the side. Square nuts slide in, can't spin, and you can make the slot as long as you want. Hobby designers commonly leave around 0.3 mm of clearance on these.

And because it's your design, you're not stuck with six sides. The Nasty Bastard nut and bolt generator builds nuts as hex, square, circle, star — or triangle, if you want a nut that only you can undo.

The hydrant people would be proud.

So which shape's going in your next nut trap?

Frequently asked questions

Why are nuts hexagonal instead of square?
A hex nut can be re-gripped every 60° with a 6-point socket or box wrench (a square needs 90°), and with an open-end wrench you can flip it to work in about a 30° swing. Six sides also keeps the corners big enough not to round off, and a hex wastes less material than a square cut from round bar.
Why are fire hydrant nuts pentagon shaped?
A pentagon has no parallel sides, so ordinary open-end or adjustable wrenches can't grip it. Many US hydrants use a pentagonal operating nut specifically to make unauthorized use without the proper hydrant wrench difficult.
Are square nuts better than hex nuts?
For some jobs, yes. Square nuts have more bearing surface, resist loosening, are hard to round off, and can't spin in a slot — which makes them great in channels, wood, and 3D-printed side-slot nut traps. Hex nuts win when you need to turn them in tight spaces.
Can I use a 12-point socket on a hex nut?
It works and re-grips every 30°, but a 12-point socket only grips near the corners and has been known to round off 6-point fasteners. Use a 6-point socket when you have room.