Email us

Este artículo está en inglés. Ver el sitio en español

Cet article est en anglais. Voir le site en français

Dieser Artikel ist auf Englisch. Website auf Deutsch ansehen

Este artigo está em inglês. Ver o site em português

本文为英文。 查看中文网站

Compact DIN rail enclosure for a controller with modules

Size the box from the depth stack, not the footprint: from the rail plane to the closed lid, a compact controller needs its body depth, about 1.2 in [30 mm] for the Ethernet plug and boot, plus 1 in [25 mm] of cable turn. A 12 x 10 x 8 in interior usually beats a wide flat box.

NEMA4 Enclosure engineering team · Published November 25, 2026 · 6 min read

Short answer: size the box from the depth stack, not the footprint. From the DIN rail plane to the closed lid you need the controller body, about 1.2 in [30 mm] for the Ethernet plug and its strain-relief boot, and 1 in [25 mm] of cable turn, so a 12 in [300 mm] tall x 8 in [200 mm] deep interior usually beats a wide flat box. Set the rating from the real exposure, then keep it with the maker's documented glands. This article uses a compact controller with two expansion modules as the worked example; replace the module widths and connector projection with the ones on your drawing before you order.

The depth stack decides the depth

A bare-device fit lies. The controller slides onto the rail and the lid closes, so the footprint looks fine, and then the first Ethernet plug fouls the lid. Measure the stack in four numbers, all taken from the rail plane:

Item Typical value Where it comes from
Rail clip to device back 0.6 in [15 mm] the DIN rail clip height
Device body depth 2.5-3.5 in [65-90 mm] the controller datasheet
Plug plus boot projection 1.2 in [30 mm] the assembled cable, measured
Cable turn before the route 1 in [25 mm] bend room so the port carries no side load

That stack lands at 5.3-6.3 in [135-160 mm] from the rail plane to the lid. Add the rail-to-rear-wall clearance and wall thickness, and an 8 in [200 mm] interior depth carries it with margin. A box that is 16 in [400 mm] wide but only 5 in [130 mm] deep fails this stack on every port that faces front.

A right-angle Ethernet plug cuts the projection roughly in half, to about 0.6 in [15 mm], and it is the first thing to try when a depth works everywhere except one port. The cable still needs its 1 in [25 mm] of turn; the saving is only in the straight section.

For the full backplate method, the guide to backplate and DIN rail layout walks the rail plane, duct and clearance zones, and how to size an electrical enclosure covers the whole envelope including wire bending space at terminals.

Width on the rail: count the modules, then the ends

Width is easier, and most people overbuy it. Add the device widths and reserve both ends.

Worked example: a compact controller 3.5 in [90 mm] wide with two expansion modules at 1.8 in [45 mm] each.

  • Devices on the rail: 3.5 + 1.8 + 1.8 = 7.1 in [180 mm].
  • End clearance for the cable turn and terminal access: 1.5 in [40 mm] per end, so 3 in [75 mm] total.
  • Minimum usable rail length: 7.1 + 3 = 10.1 in [255 mm].

A 12 in [300 mm] tall interior gives about 12 in of usable rail length and leaves 1.9 in [48 mm] spare. That same 12 in tall x 10 in wide x 8 in deep interior also holds a small power supply and a row of terminals under the controller, which is why it is the usual answer for this build. When you add a supply and field terminals, go to 16 in [400 mm] tall; the enclosure selector filters stainless sizes by inside height, width and depth so you can see which standard sizes clear the stack. The minimum-depth method is set out in more detail in enclosure size for DIN rail devices.

Read the usable dimensions off the maker's internal drawing, not the outside size. Removable mounting panels, bosses and door hardware eat 0.2-0.5 in [5-13 mm] per surface, and our stainless wall-mount boxes, the junction box line among them, print each size's panel and DIN capacity on the page.

IP65 or IP67: match the second digit to the water

Both are dust-tight: the first digit 6 means dust-tight under IEC 60529. The second digit is the decision.

Exposure Second digit Test behind it
Rain, splashes, condensation IPX3, IPX4 spraying and splashing water
Washdown, hose at a distance, driving rain IPX5 6.3 mm nozzle, 12.5 L/min jets
Standing or flood water, temporary submersion IPX7 1 m [3.3 ft] immersion for 30 min

For a wall-mounted controller, IP65 is usually the right rating: it is dust-tight and jet-proof, and a wall-mounted box never sits in 1 m of water. IP67 buys immersion you will not use and, in compact plastic boxes, often costs you depth because the walls run thicker. If the specification or a US inspector calls out a NEMA type instead, IP ratings alone do not satisfy it; the ratings guide on NEMA 4X and IP66 explains the pairing, and IP65 vs IP67 enclosure: which one to order works this same comparison in more depth. Note that ratings are manufacturer ratings; our boxes are rated NEMA 4X / IP66 by the manufacturer and are not UL listed.

The rating belongs to the finished assembly

The rating on the label belongs to the closed, penetrated, finished assembly. Three things break it in the field:

  1. Cable entries. Every penetration carries a gland whose sealing range covers the cable's outside diameter and whose documented installation preserves the enclosure rating. An IP68-marked gland alone does not carry the box's rating; use the enclosure maker's approved gland and hole method, or verify the maker's documented accessory list before selecting another one.
  2. Unused openings. Cap each one with a rated plug. Tape and unsealed blanks are the two most common leaks we see on returned photos.
  3. Condensation. A sealed compact box with a cycling load breathes through its gaskets as the interior cools, and water arrives without any hole at all. A small anti-condensation heater or a breather drain fixes it; the condensation guide sizes it, and condensation in an IP67 project box shows the entry-level version of the same fix.

The cutouts, glands and HMI windows guide gives the hole sizes and placement rules for the entry plan. Vibration on the mounting structure works glands loose over time; cable glands loosening under vibration covers the locknut and thread treatment that holds them.

Heat: a sealed compact box rejects heat slowly

The controller and its modules dissipate a few watts each, and a sealed stainless box sheds that heat through its walls. As a screening example, take a 12 x 10 x 8 in box with about 3.9 ft² [0.36 m²] of surface. Use the stainless wall heat-transfer coefficient of 3.7 W/m²K and a 10 K [18 F] allowed rise over a 35 C [95 F] ambient.

The walls then reject roughly 0.36 x 3.7 x 10 = 13 W. That covers a controller with two I/O modules comfortably; it does not cover a hot power supply. Add the dissipations from the datasheets, and if the total approaches the wall rejection at your ambient, go up a size, because the larger surface area rejects heat in proportion to its area. Compact controller enclosure sizing runs this check for a protected panel, and why a controller reboots after closing the enclosure lid is what a marginal thermal build looks like in the field.

What to put on the order

Line Spec for this build
Material 304 stainless indoors; 316L for washdown, coastal or chemical air
Interior size 12 in tall x 10 in wide x 8 in deep [300 x 250 x 200 mm] minimum; 16 in [400 mm] tall with a supply and terminals
Rating IP65 minimum; manufacturer-rated NEMA 4X / IP66 stainless for washdown
Cutouts Gland holes on the bottom wall, sized to the cable ODs, clear of the rail plane
Accessories Rated plugs for unused openings; breather drain or small heater where the load cycles

Specify the depth stack, not just the footprint: give the plug projection and cable turn you measured, and we cut and build to your drawing, delivered in 10 business days worldwide, counted from your order or, for custom work, from your approval of the drawing. You can start from a standard size in the stainless enclosure range or send the stack straight to custom enclosures.

Catalog dimensions to compare

Compare these catalog dimensions with your component layout. Open each enclosure for its rating, material and usable space, then check those specifications against your application.

EnclosureMaterialOutside H x W x D / displayRating
12 × 10 × 8 in304 stainless12 x 10 x 8 inRated NEMA 4X / IP66 by the manufacturer; not UL listed
12 × 10 × 6 in304 stainless12 x 10 x 6 inRated NEMA 4X / IP66 by the manufacturer; not UL listed
20 × 16 × 8 in304 stainless20 x 16 x 8 inRated NEMA 4X / IP66 by the manufacturer; not UL listed
24 × 20 × 8 in304 stainless24 x 20 x 8 inRated NEMA 4X / IP66 by the manufacturer; not UL listed

Questions

Is IP67 always better than IP65 for a controller enclosure?

No. IP65 means dust-tight and protected against low-pressure water jets, which covers rain, hose-down at a distance and washdown splashes. IP67 adds temporary immersion at 1 m [3.3 ft] for 30 minutes, which a wall-mounted controller never sees. Pick IP67 only when the box can sit in standing water or flood water; otherwise IP65 or a manufacturer-rated NEMA 4X / IP66 wall-mount box is the right order.

How much depth does an Ethernet plug and boot need inside the enclosure?

Plan about 1.2 in [30 mm] from the controller's front face to the end of the installed plug and its strain-relief boot, then 1 in [25 mm] more for the cable to turn without kinking. A right-angle plug cuts the projection roughly in half, to about 0.6 in [15 mm], when the port geometry allows one.

Can I drill the cable entries myself and keep the rating?

Yes, when you cut clean holes matched to the gland's sealing range and follow the enclosure maker's instructions for holes and glands. An IP68-rated gland does not by itself preserve the enclosure rating: the assembly rating depends on the maker's documented gland and mounting method. Cap unused openings with rated plugs, not tape.

How tall an enclosure does a controller with two expansion modules need?

For a compact controller about 3.5 in [90 mm] wide plus two modules at 1.8 in [45 mm] each, 5.5 in [140 mm] of devices on the rail, a 12 in [300 mm] tall interior leaves about 3 in [75 mm] per end for the power supply, terminals and cable turn. Go to 16 in [400 mm] tall when you add a supply and field terminals, which is the usual real-world answer.

Checklist before you order

Specify it once, built to your drawing

  • Environment and NEMA type: Type 1, Type 3R, Type 4, Type 4X, Type 6P, Type 12, Type 13 (manufacturer ratings, not UL listed)
  • Material: 304 stainless steel, 316L stainless steel, Powder-coated carbon steel, Aluminum, Polycarbonate, Fiberglass (FRP)
  • Size: inside or outside height, width and depth, with the depth your deepest component needs
  • Cutouts, glands and windows, dimensioned from one datum on each face
  • Mounting and access: wall, pole or stand, hinge side, mounting panel
  • Quantity: from one piece

Delivered in 10 business days, anywhere in the world. Counted from your order; for custom work, from your approval of the drawing.

Build it from 12 × 10 × 8 inRequest a custom quote

NEMA 4X enclosures: sizes for this job

Keep reading

More on layout and installation

All articles

Buying guides

The guides behind this answer

All guides