Home/Calculators/Shaft Key Size Calculator
Zone A — Power Transmission

Shaft Key Size Calculator

Find square key width, height, and the minimum key length needed to transmit a given torque, checked against both shear and bearing (crushing) stress.

L = 2T/(τ·w·d) and L = 4T/(σ·h·d)

Enter your values

Torque, shaft diameter, key size, and allowable stresses.

Suggested for 25 mm shaft: w = h = 6 mm (rule of thumb, w ≈ d/4)
mm minimum key length
Shear-limited length
Bearing-limited length
Governing case
Enter positive, non-zero values for all fields.

How this calculator works

A key transmits torque from a shaft to a hub (or vice versa) through shear across its width and bearing across its height. The force at the shaft surface is F = 2T/d. Checking each failure mode separately:

Shear: L = 2T / (τ · w · d) Bearing: L = 4T / (σ · h · d)

T is torque, d is shaft diameter, w and h are key width and height, τ is the key material's allowable shear stress, and σ is its allowable bearing (compressive) stress. The required key length is the larger of the two results — whichever failure mode governs.

Standard square key proportions

Shaft diameterKey width × height
Up to 22 mm6 × 6 mm
22 – 30 mm8 × 7 mm
30 – 38 mm10 × 8 mm
38 – 44 mm12 × 8 mm
44 – 50 mm14 × 9 mm

These follow common square/rectangular key convention (roughly w ≈ d/4). Always confirm against the applicable standard (e.g. DIN 6885 / ANSI B17.1) or the mating component's drawing.

Frequently asked questions

Why does bearing stress usually need a longer key than shear?

Only half the key height engages the shaft's keyway (the other half sits in the hub), so the bearing area is smaller than the full shear area — bearing stress is typically the governing, more conservative check.

Should I add a safety margin on top of the calculated length?

Yes — this gives the theoretical minimum length. Standard practice is to round up to the next available stock key length and confirm the key doesn't run past the hub or into a shaft fillet.