Tuesday, November 25, 2025

Printing holes for a snug fit

I often want to design and print parts which fit on a metal shaft with a diameter of a few millimetres. 3D printers don't accurately print holes. The diameter of the hole in the printed part is typically less than designed for, due to factor such as the plastic squishing and expanding horizontally or the plastic expanding as it leaves the nozzle. If the part is intended to run freely on the shaft, it's not a problem. Just drill the hole out, for example with a pin vice, and maybe sand or file it if needed. I have also tried using a reamer to improve the finish, though I am not sure it makes any difference.

It is a little more of a challenge to make parts with holes that provide a snug fit. This would be for the case when you want to the part to be rigid, or at least firm, on the shaft. You can design the part with a hole for a set screw. I have often done this with 2mm and 3mm screws. I usually design the part with a hole 1.8 or 2.8mm for the screw and then use a M2 or M3 machine screw. It generally works quite well. I have had less success using grub screws. I think their thread isn't deep enough to cut into the plastic. Tapping the hole works. It is still not always a satisfactory solution as some parts don't have a good surface for placing a hole or for getting a screwdriver. Think of a gear with a hub the same height as the teeth, for example. Also, there are cases where you want a fit that will hold under normal use, but where the part can move on shaft if enough force is applied.

I decided to try experiments with a few different ways of making a snug fit. In each case, the shaft is a nominal 4mm in diameter and made from stainless steel. The measured size was about 3.95mm. Usually I find steel shafts are slightly under the nominal size and brass shafts are slightly over. The obvious method is just a simple hole, which I did at 4.0, 4.1 and 4.2mm diameter. I also used a 6mm hole with ribs in it. The ribs are 0.4mm wide. You have to use the Arachne slicing algorithm for them. Finally, tried a 4.0mm hole with a 10mm by 1mm cut out. The designs look this like:

Slicing for the ribbed version shows that there will be a single line of filament:
The tips of the ribs are designed to be 4mm from the center. Note that it prints well, but not perfectly, with some stringing between the ribs.

One preliminary comment before the results. In the past, I think we would have worried about things like whether the printer was square, calibration of the motion system and extruder, whether the filament was precisely 1.75mm diameter and so on. In my view, these are not really concerns for current printers  and filaments.

The shaft would not fit at all in the 4.0 and 4.1mm holes and was a bit loose in the ribbed version. It was fitted OK in the 4.2mm hole but was still a bit loose. The fit for the cutout hole was good: I could get the shaft in with a little force, and then it held very firmly. I could make it slip when turning the part on the shaft only with a lot of force.

These tests were with Hatchbox black PLA, using PrusaSlicer's 0.2 structural setting and the filament profile for Hatchbox PLA, Arachne slicing, and some extra elephant's foot compensation. The latter was because the first one or two layers sometime squish a bit more, and may be a tight fit for these layers but not for the others.

With Amazon Basics Gold Silk PLA using the Generic PLA Silk filament profile, the results were more or less the same. The only difference is that the 4.1mm hole was usable and was a tight fit. This wasn't what I expected. Maybe it is because silk filament is sometimes a bit more slippery.

There are no big conclusions to draw here. I hope it will provide some guidance for my designs in future.