kapy academy

ESP32 and other small boards

15 min readUpdated Nov 2026

Unlike a Raspberry Pi or an Arduino, most ESP32 development boards have no mounting holes: the ESP32-DevKitC V4, the ESP32-S3-DevKitC-1 and every XIAO are held by their pins or their edges, against a stop that takes the force of the USB cable. On top of that, the module's antenna, which on the DevKitC sticks out 6 mm past the edge of the board, needs clear space that a tight enclosure will not give it. Those two things drive the design.

Board dimensions

Dimensions in mm, origin at the lower-left corner of the PCB seen from above, with the USB edge at the bottom.

Outlines, holes, USB and antenna
Board Outline Mounting holes USB Antenna Source
ESP32-DevKitC V4 27.94 × 48.26, r 1.0 None Micro-USB, short edge WROOM module's, 18 wide (x 5.0–23.0), overhangs the opposite edge by 6.04 Espressif DXF
ESP32-S3-DevKitC-1 v1.1 25.4 × 62.87, r 0.5 None Two micro-USB on the short edge: UART at x 6.0, native USB at x 19.4 Module's, overhangs the opposite edge by 6.29 Espressif DXF
NodeMCU DevKit 1.0 (ESP8266, "v2") 25.4 × 48.26 4 × Ø2.92, 2.286 from the edges: 20.83 × 43.69 between centers Micro-USB On the PCB NodeMCU reference Gerbers
D1 mini V4 (ESP8266) 25.4 × 34.3, lower-left corner cut away 2 × Ø2.0 at (2.5, 31.0) and (22.9, 31.0): 20.4 between centers USB-C On the PCB wemos.cc drawing
XIAO ESP32C3 20.96 × 17.78, r ≈ 1.9–2.0 None USB-C, protrudes 1.52 External, U.FL connector Seeed DXF
XIAO ESP32S3 17.78 × 21.14, r ≈ 1.9–2.0 None USB-C External, U.FL connector Seeed DXF
XIAO RP2040 21.10 × 17.78, r ≈ 1.9–2.0 None USB-C, protrudes 1.43 None (no Wi-Fi or Bluetooth) Seeed DXF
Feather (classic 2.0 × 0.9″ format) 50.8 × 22.86, r 2.54 4, 2.54 from the edges: 45.72 × 17.78 between centers. Left pair Ø2.5; the right pair varies by model (HUZZAH32: Ø2.2 at y = 1.84 and 20.96) Left short edge; micro-USB on the classic boards, USB-C on many recent ones HUZZAH32: module flush with the right edge; others vary by model Adafruit Eagle files and Feather specification

Source: each manufacturer's drawings, cited in the table. ESP32 is a trademark of Espressif Systems, XIAO of Seeed Technology and Feather of Adafruit Industries. KapyCAD is not affiliated with any of them.

On the S3-DevKitC-1, the dimension labeled on the drawing is 62.74, but the drawn outline measures 62.87: your board could be either, so allow for that 0.13. The XIAO ESP32C3 and ESP32S3 differ by 0.18 on the long side: a clearance of 0.2 per side absorbs it, but if you want a close fit, draw each pocket to its own size.

If you hold the board by its pin headers (the cradle in the next section), these are the dimensions you need. The DevKitC V4 has 2 × 19 pins at 2.54 pitch, with the rows 25.4 apart and their centers 1.24 and 1.30 from the long edges; the first pin is 1.29 from the USB edge and the last 1.25 from the antenna edge. The S3-DevKitC-1 has 2 × 22, with rows 22.86 apart and 1.27 in from each long edge. On the XIAO boards, the rows of through-holes are 15.24 apart, 1.27 in from the castellated edge. On all of them, the pin solder joints occupy a band about 2.5 mm wide along each long edge, corners included.

None of these drawings gives the PCB thickness. The usual value is 1.6, but measure yours with callipers before you design a slot that grips the edge.

The 6.04 overhang on the DevKitC belongs to the version with the ESP32-WROOM-32 module, the one Espressif draws. The same board is sold with WROVER modules and with external-antenna variants on U.FL (-U, -IE), which are shorter and have no published dimension: measure yours.

Clones have no drawing. The 30- and 38-pin "ESP32 DevKit V1" boards and the NodeMCU "V3" (LoLin, roughly 57–58 × 31–32 mm) are sold under many names and change width, holes and USB from one maker to the next; even NodeMCU boards sold as "v2" vary between clones. The same goes for D1 minis older than the V4: wemos.cc publishes no drawing for the V3.1, and micro-USB copies are in circulation. Measure yours (Measuring an undocumented standard).

The table does not cover every board available as of late 2026: boards with the ESP32-C6, C5 and P4, the XIAO ESP32C6, the XIAO ESP32C5 and the Feather ESP32-S3 and V2 with USB-C. For any of them, start from its drawing.

22.86no holesESP32-S3-DevKitC-1USB25.4no holesESP32-DevKitC V4USBantenna, overhangs 6.04 (6.29 on the S3)rows 25.4 apart (DevKitC) and 22.86 (S3)NodeMCU 1.0USBFeatherUSBvaries by model20.83 × 43.69 (NodeMCU) · 45.72 × 17.78 (Feather)20.4D1 mini V4USBcut-away cornerno holesXIAO ESP32C3USBU.FL connectorcastellated edge
Six of these boards at the same scale, all with the USB at the bottom. The DevKitC and XIAO boards have no holes; on the DevKitC the antenna sticks out 6 mm past the edge.

Holding a board with no holes

Start with the load. Under the USB Type-C specification, inserting the plug takes 5 to 20 N and pulling it out 8 to 20 N (6–20 N after 10,000 cycles); micro-USB forces are of the same order. The board has to take that force in both directions without moving: on insertion, against a stop behind it; on removal, against a stop in front, on the USB side.

Pressing down from above will not stop the pull. A rib pushing the board against the floor only holds it by friction, and to resist 20 N with a coefficient of 0.3 it would have to press with about 67 N (about 33 if it rubs on both top and bottom), which a printed lid cannot deliver and creep would relax anyway. What stops the pull is the edge of the PCB bearing against the USB wall, or against a step behind that edge; whatever comes down from the lid only stops the board lifting.

There are four ways to hold it, firmest first:

  1. Give it holes: solder two female headers to a piece of 2.54 mm pitch perfboard, or to a carrier PCB of your own, screw the carrier onto standoffs and plug the board on top. The board stays removable and the carrier takes the cable's force; make the standoffs as in Enclosures and mounts for Arduino.
  2. A cradle for the pin headers: the board goes pins down, and the plastic body of each header drops into a printed slot, one per row, at the row pitch. Each slot is the header body (measure it: usually around 2.5) plus 0.2 per side (Real printed clearances). Close it with a stop at the far short edge, the USB wall in front and two lid ribs on the PCB.
  3. Stops on the short edges that bear on the face of the edge without reaching over the PCB. The long edges carry the pin solder joints, and on the DevKitC the corners of the short edges carry pins and the module overhangs between x 5 and x 23 at the antenna end.
  4. A fitted pocket for a XIAO: outline plus 0.2 per side, a back wall as the insertion stop and, on the USB side, a wall with an opening sized to the connector (it protrudes 1.52 on the C3 and 1.43 on the RP2040) for the edge to bear against. At the far end, a snap lip or the lid stops it lifting; size the lip as in Print-friendly snap fits and keep it off the U.FL connector, the buttons and the castellated-edge joints.

Anything that bends, such as a clip or a tab, prints with its length in the layer plane, lying flat or on edge, never standing up (Layer orientation for mechanisms).

Underneath, the soldered header tails and the components on the underside need at least 3 mm of clearance. The XIAO ESP32C3 and ESP32S3 have their battery pads on the underside: keep anything conductive off them.

Three boards in this family do have holes. The NodeMCU 1.0 has Ø2.92: it takes M2.5 with 0.4 mm of clearance. On the Feather, the left pair (Ø2.5) takes M2 with clearance; use it as your reference, because the right pair changes from model to model. The D1 mini V4 has two Ø2.0 holes, where an M2 goes in with no clearance: you are better off with two printed Ø1.6 locating pins (0.4 under the hole) and something holding it from above. The pilot and the standoff wall are in Self-tapping screws in plastic and Designing for heat-set inserts.

In Seeed's tests, the XIAO ESP32S3 Sense with the camera running reaches 63.6 °C on its underside without a heatsink, and 53.5 °C with the maker's dual heatsink, in open air; inside a closed box it gets hotter. Under load, PLA works up to about 40 °C, PETG up to 50 and ASA up to 80–85 (Heat, cold, sunlight and chemicals). Print the cradle in ASA, keep plastic off the underside and ventilate the box.

slot = body + 0.2 per sidecradlelid ribstopUSB wall: stops the pullplugging in, 5–20 Nunplugging, 8–20 Npins 1.24–1.30 from the edge: do not grip hereUSB-C, protrudes 1.52snap lipstoppocket + 0.2 per side
A USB-C plug pushes up to 20 N going in and pulls up to 20 N coming out: the board needs a stop behind it and the USB wall in front. Never hold it by the long edges: that is where the pins are.

The antenna

The ESP32 hardware design guidelines ask for the PCB antenna to sit outside the base board or at its edge, and recommend at least 15 mm of clearance in every direction around it. That is why the DevKitC module overhangs by 6.04 mm (6.29 on the S3): the board already does its part, and the enclosure must not undo it.

What hurts it, worst first:

  • metal near the antenna: screws, heat-set inserts, magnets, a battery or a metal lid;
  • filaments with conductive or signal-absorbing fillers: carbon fiber, or real metal powder in the metallic-look ones;
  • thick plastic pressed against the antenna.

Most small enclosures do not have room for 15 mm. In that case, put the antenna end against a wall of the box, not in the middle; a 1.5–2 mm wall of PLA, PETG or ASA is the usual compromise. The guidelines also ask you to keep the antenna away from metal; in practice, nothing metallic within those 15 mm: no standoffs with inserts, screws or magnets at that end, and the wall on that side stays plain plastic.

Then measure. With the board always in the same place relative to the router, read the signal strength (RSSI) the board reports with no enclosure and with the box closed. What counts is the difference between the two readings; if it drops, look for metal near the antenna first.

The XIAO ESP32C3 and ESP32S3 come with a separate flexible antenna on a cable with a U.FL connector. Stick it flat to the inside face of a plastic wall, away from the board's ground plane and from any metal. Leave a channel for the cable and do not bend it sharply next to the connector: U.FL is not designed for frequent mating. The XIAO C5 keeps U.FL and the C6 combines an on-board ceramic antenna with U.FL: check which antenna yours ships with.

On the Feather HUZZAH32, the module sits flush with the right-hand short edge: apply the same rule, with that end against a plastic wall and, if you put standoffs at the right pair, print them without inserts.

heat-set insertmagnetantennabatterymetalantennaEspressif: ≥ 15 mmplain plastic walloverhangs 6.04 · PCB + antenna 54.30U.FL antenna stuck to the lidcable channel
The antenna needs air and no metal nearby. If the box cannot give it 15 mm, take the antenna to a plastic wall and everything metallic to the other end.

Example: a DevKitC V4 in a closed box

Inside length: from the USB edge to the tip of the antenna is 48.26 + 6.04 = 54.30 mm, and the connector sticks out about 0.3 on the other side. With the 15 mm Espressif asks for in front of the antenna, that is 0.3 + 54.30 + 15 ≈ 69.6 mm, if you have room; without it, the minimum is ≈ 54.8 with clearance. A box drawn from the PCB alone (48.26 + 2 × 0.2 = 48.7) will not take the board: the antenna hits the far wall. Forget those 6 mm and the board does not go in.

Width: for the PCB, 27.94 + 2 × 0.2 = 28.34 mm. The antenna is 18 wide and centered: with 15 mm either side you would need 48 mm. In a 28 mm box, keep the long walls plain at that end and put nothing metallic there.

USB side: the micro-USB body sticks out about 0.3 mm past the PCB edge (a figure taken from the silkscreen, not a mechanical dimension). Put the inside face of the wall against the PCB edge: the connector pokes 0.3 mm into the opening and the plug reaches it. The opening size and wall thickness are in Connector cutouts.

Holding: a cradle with the slots 25.4 apart. At the antenna end, two small stops against the face of the edge, near the corners but outside x 5–23 and without riding over the PCB: they touch the board, not the module. At the USB end, the wall takes the pull, with the PCB edge bearing against it. Above, two lid ribs on the PCB, one either side of the connector, stop it lifting.

Height: add up the floor, the header body and pin length, the PCB, the module can and at least 2 mm of air under the lid; for example, floor 2 + header 2.5 + pins 6 + PCB 1.6 + module 3.2 + air 2 ≈ 17 mm. Measure your pins, because they vary between headers. The tolerances of that sum are covered in Assemblies and tolerance stackups.

When it fails

Symptom, cause and fix
Symptom Cause Fix
The board slides back when you plug in, or comes out with the cable Only friction holds it: the far stop or the USB wall is missing Stop against the face of the far edge (on the DevKitC, outside the antenna's width) and the USB wall against the edge
The DevKitC will not fit the box made for it The antenna, which overhangs 6.04, was not counted Length = connector + PCB + antenna + clearance
Wi-Fi range drops when the lid goes on Metal or conductive filament near the antenna, or antenna in the middle of the box Antenna against a plastic wall, no inserts, screws or magnets at that end; compare RSSI
A slot on the edge crushes joints or shorts pins The joints are 1.24–1.30 from the long edges and, on the DevKitC, at the corners of the short ones Hold by the header bodies or with stops against the face of the edge, without reaching over the PCB; an edge slot only suits boards with no pins at the corners
The clone's holes do not line up with the standoffs There is no drawing and every maker puts them somewhere else Measure the board (Measuring an undocumented standard)
A PLA cradle under a XIAO ESP32S3 Sense gives way 63.6 °C on the underside with the camera running ASA, no plastic against the underside, ventilation
The Feather's right-hand screws will not go in The right pair changes from model to model Reference the left pair; on the right, standoffs measured on your board, or none

How to test it

Before the whole box, print only the floor with the cradle, the stops and the stretch of wall with the USB opening: a few minutes' print. Fit the board and plug and unplug the cable ten times: nothing should move (Test coupons). Then close the box and compare the RSSI with and without it.

See also

Design it in KapyCAD

Draw the part to the standard's dimensions and keep them as values you can edit.

Free plan, no card. Runs in your browser, nothing to install.

Open the editor

Still have a question?