Snap-Fit Design: How to Calculate a Cantilever Latch

Snap-Fit Design: How to Calculate a Cantilever Latch

Snap-fit design is the work of sizing a flexible plastic feature so that it bends, clears an undercut, and springs back to lock two parts together. Flux is an AI hardware engineer, and it does this work for you. Describe the board and the lid, and Flux designs the enclosure with the latches, calculates the strain and the forces of each latch, checks that the latches clear the board, and prepares the parts for manufacturing. A snap-fit lid takes Flux a few hours, not the days of hand calculation, CAD rework, and print iterations that it takes without Flux.

This guide first shows how to ask Flux to design a cantilever snap fit. Then it gives the three formulas behind the calculation, works through a real latch for an electronics enclosure, and lists the design rules that keep the latch from cracking in production.

How Flux designs a snap fit

Flux designs the board and the enclosure in one project, so it designs the latch around the real board, not around a box with a guessed size.

Ask Flux to design the enclosure with the latches:

Design a two-part PC/ABS enclosure for this sensor board, with 2 mm walls and a lid that holds with four
cantilever snap-fit latches. The lid must open by hand for battery changes. Keep the M12 connector opening
clear and leave 1 mm of clearance around the board.

Flux creates the enclosure as editable CAD code, with draft angles, uniform wall thickness, ribs, bosses, snap fits, and a parting line. It can make each latch dimension a named parameter, so you change the beam length or the undercut and Flux rebuilds the part.

Then ask Flux to calculate the latch:

Calculate the strain, deflection force, assembly force, and separation force of each lid latch. Use PC/ABS
with a 1.5% allowed strain for repeated use, a 2,000 MPa secant modulus, and a friction coefficient of 0.5.
If the strain is above the limit, taper the beam and recalculate.

Flux states the formulas and the assumptions with the results, the same way as the worked example below. To check the root of the beam and the wall behind it, ask for a stress and deflection analysis of the latch with its material, load, and support conditions. Flux reports the peak stress and deflection with units and locations.

Then check the fit and get the part made:

Check that each latch can deflect 0.9 mm inward without touching the board or its components. Then analyze
the tolerance stack-up from the hook to the latch window and report the worst-case and RSS engagement.
Prepare the lid and the base for SLA printing in a tough resin and get a 3D-print quote.

Flux checks the clearance between the latch and the board, computes worst-case and RSS stack-ups, and prepares the parts for 3D printing, CNC machining, or injection molding. See Design new parts, Mechanical analysis, Fit and clearance, and Make mechanical parts in the Flux docs, or read more about mechanical design in Flux.

Start Free Trial

Types of snap fits

There are three main types of snap-fit joints:

  • Cantilever snap fit. A beam with a hook at its free end. The hook slides over a ramp, the beam bends, and the hook drops into a window or behind a ledge. This is the type that most enclosure lids, battery doors, and bezels use.
  • Annular snap fit. A ring-shaped bead on a shaft that snaps into a groove in a mating bore. Pen caps and round sensor housings use it. The hoop strain in the bore sets the design.
  • Torsion snap fit. A latch arm on a torsion bar. You press one end of the arm to release the other end. Removable covers and service doors use it.

The rest of this guide is about the cantilever snap fit, because it is the one that you design most often.

Cantilever snap-fit geometry

A cantilever latch has six values that control it:

  • L: beam length, from the root to the hook.
  • h: beam thickness at the root, in the direction that the beam bends.
  • b: beam width.
  • y: undercut, the distance that the hook must move to clear the mating part. This is the beam deflection.
  • α: lead angle, the angle of the ramp that the mating part pushes on at assembly.
  • α′: retention angle, the angle of the face that holds the parts together.

The material gives two more values: the allowed strain ε and the secant modulus Es, which is the stress divided by the strain at that strain. The friction coefficient μ between the two parts sets the assembly force.

The cantilever snap-fit formulas

For a beam with a rectangular section and a constant thickness, the standard design-guide formulas are:

Value Formula
Strain at the root ε = y · h / (0.67 · L²)
Deflection force P = (b · h² / 6) · (Es · ε / L)
Assembly force W = P · (μ + tan α) / (1 − μ · tan α)
Separation force W′ = P · (μ + tan α′) / (1 − μ · tan α′)

If the beam tapers to half its root thickness at the hook, the factor 0.67 in the strain formula becomes 1.09. The same undercut then gives about 40% less strain.

Typical allowed strains for a snap fit that you assemble one time are about 4% for polycarbonate (PC), about 2.5% for PC/ABS and ABS, and about 2% for glass-filled nylon. For a latch that opens and closes many times, use about 60% of that value. Use the value from the data sheet of the resin grade that you buy.

Worked example: a lid latch for a sensor enclosure

The device is an industrial sensor node: a controller board with a radio and an M12 connector, in a two-part PC/ABS enclosure. The lid holds to the base with four cantilever latches, one at the center of each long side and one at each end. A technician opens the lid in the field to change the battery, so the latch must open and close many times without damage.

Inputs

Input Value Reason
Material PC/ABS Impact strength and flame rating for the enclosure
Allowed strain, one assembly 2.5% Design-guide value for PC/ABS
Allowed strain, repeated use 1.5% 60% of 2.5%, because the lid opens for battery changes
Secant modulus Es 2,000 MPa Secant value at about 1.5% strain
Friction μ 0.5 PC/ABS on PC/ABS
Beam length L 12 mm Fits inside the 16 mm lid skirt
Root thickness h 1.6 mm 80% of the 2.0 mm wall, which prevents sink marks
Width b 6 mm Clears the ribs next to the latch
Undercut y 0.9 mm Enough engagement to hold the lid against a drop
Lead angle α 30° Easy assembly by hand
Retention angle α′ 45° The lid comes off with a firm pull, without a tool

Step 1: Check the strain

For a beam with a constant thickness:

ε = 0.9 × 1.6 / (0.67 × 12²) = 1.44 / 96.5 = 1.49%

That is just below the 1.5% limit for repeated use. The latch works, but it has almost no margin. A molding tolerance of +0.1 mm on the undercut increases the strain by 11%, to 1.66%, which is above the limit.

Step 2: Taper the beam

Taper the beam from 1.6 mm at the root to 0.8 mm at the hook. The factor changes from 0.67 to 1.09:

ε = 0.9 × 1.6 / (1.09 × 12²) = 1.44 / 157 = 0.92%

The strain is now 39% below the limit for repeated use. A +0.1 mm undercut tolerance gives 1.02%, which is still well inside the limit. The stress at the root is Es × ε = 2,000 × 0.0092 ≈ 18 MPa, which is far below the yield strength of PC/ABS. The taper also removes material at the hook, so the beam fills and cools more evenly in the mold.

Step 3: Calculate the deflection force

P = (6 × 1.6² / 6) × (2,000 × 0.0092 / 12) = 2.56 × 1.53 = 3.9 N

This is the force at the hook that bends the beam by the full 0.9 mm undercut.

Step 4: Calculate the assembly and separation forces

Assembly, with the 30° lead angle (tan 30° = 0.577):

W = 3.9 × (0.5 + 0.577) / (1 − 0.5 × 0.577) = 3.9 × 1.51 = 5.9 N per latch

Separation, with the 45° retention angle (tan 45° = 1.0):

W′ = 3.9 × (0.5 + 1.0) / (1 − 0.5 × 1.0) = 3.9 × 3.0 = 11.7 N per latch

With four latches, the lid snaps on with about 24 N and comes off with about 47 N. That is a firm press to close and a deliberate pull to open, which is the result that the battery-change requirement asks for.

Step 5: Choose the retention angle on purpose

The retention angle decides whether the joint opens. At 45°, the lid comes off by hand. A steeper angle increases the separation force quickly. When μ · tan α′ reaches 1, the term 1 − μ · tan α′ goes to zero and the joint locks: friction holds the hook, and the beam breaks before the joint opens. For μ = 0.5, that happens at about 63°. A 90° face is vertical and does not push the beam back at all, so that joint is permanent. Use 63° or more only for a part that you never open, or add a release slot so that a tool can push the hook back.

Result

Value Constant beam Tapered beam
Strain at 0.9 mm undercut 1.49% 0.92%
Strain at 1.0 mm undercut (tolerance) 1.66% 1.02%
Deflection force P 6.4 N 3.9 N
Assembly force, per latch 9.6 N 5.9 N
Separation force, per latch 19.1 N 11.7 N

The tapered beam is the design to release. If you need more retention force, make the beam wider. Width increases the force in direct proportion and does not change the strain.

Snap-fit design rules

  • Add a root radius. A sharp corner at the root of the beam concentrates the stress. Use a radius of at least half the beam thickness, 0.8 mm in the example.
  • Keep the beam long. A beam length of at least 5 times the thickness keeps the simple beam formulas accurate and the strain low. The example uses 7.5 times.
  • Remember the wall. The formulas assume a rigid root. A thin wall under the beam bends too and adds deflection. Put a rib behind the root, or include the wall in a deflection analysis.
  • Plan the undercut for the mold. A hook on the inside of a wall needs a slide or a lifter in the mold, or a window in the wall under the hook so that the core can form the hook in the direction that the mold opens. Add draft to the beam faces.
  • Check the undercut tolerance. The strain scales directly with the undercut, so the worst case of the undercut sets the design. Add the hook height, the window position, and the lid fit to a tolerance stack-up.
  • Print the beam along its length. On an FDM printer, the bond between layers is the weak direction. Orient the part so that the layers run along the beam, not across it, and use a lower allowed strain than for a molded part.
  • Keep the latch clear of the electronics. The beam needs room to deflect inward by the full undercut. Check the clearance to the board edge, the connectors, and the tallest components at the latch.

Our guides to PCB enclosure design and hardware enclosure design cover the rest of the enclosure: mounting, openings, and assembly.

FAQs

Try it

Open a project with your board and ask Flux: “Design an enclosure for this board with a snap-fit lid, calculate the latch strain and forces for PC/ABS, and check that the latches clear the board.” Start Free Trial →

About the author

Nico Tzovanis

Nico is a professional electronics and PCB design engineer at Flux. Find him on Flux @nico

Let’s start building.

Let’s build your idea together. All you need to do is describe what you want to make, or what problem you want to solve. Flux will work with you to make it a reality.

Try it Free
Close-up of a Flux-designed printed circuit board