FreeCAD Modifying STL files

RoboFoundry
4 min readFeb 3, 2024

One of the things I have needed to do was to be able to modify some of the STL files available to change things slightly for my project. When I first started using FreeCAD I had to do a bit of research on how to do it. There are some really good youtube videos on this topic but nothing I could find that gave me quick steps. Here is my attempt to provide that documentation that might help someone.

I recently created a simple holding plate in FreeCAD to mount the Raspberry Pi camera on front of my latest robot. I’ll use that as a test to show how you can modify an existing STL file in FreeCAD. The process is simple but it has a few steps you need to do in particular order.

Import the existing STL file in FreeCAD

This is how your imported STL will look like

Here is the quick summary of steps we will following, I’ll provide step by step screenshots below.

  1. Part → Create a shape from mesh provide 0.01 resolution
  2. delete original STL/mesh
  3. select the part and then Part → Convert to solid
  4. delete the previous shape
  5. Part → Create a copy → Refine shape
  6. select new refined shape. Part Design → Create Body . this will also add base feature
  7. At this point we can create a new sketch and work on our model just like normal.

Step 1 — Create a shape from mesh

And provide the settings for creating the shape [default is 0.10, we change it to 0.01 to get better fidelity]

Here is how your sewed shape will look like

Step 2 — delete original STL/mesh from project

Step 3 — select the part and then Part → Convert to solid

Step 4 — delete the previous shape

Step 5 —select the part and Part → Create a copy → Refine shape

Step 6 — select new refined shape. Part Design → Create Body . This will also add base feature

In the left panel it will add BaseFeature which will be our base for adding any new Sketches to modify the model.

Step 7 — create a sketch and add new features to model.

Lets add a random hole to existing model to show we can modify this. This is just an example but you can apply all the operations available within sketch and part design workbench to the newly created body as if that was your original FreeCAD model.

First select the body, then Basefeature and then select the top surface of the plate and then select Sketch →Create Sketch

We can then add a new circle at any place within the sketch on the plate

Close the sketch and using Parts Design workbench click on Pocket tool. You’ll be able to chose the depth and click Ok and you should be able to see a new through hole in the original plate.

That’s pretty much it. If you want to add fillets at the edges for example you don’t have to use the sketch, you can directly use the fillet tool in Parts Design workbench and add the fillet to each vertical edge and your final output should like this:

At this point you can simply export the STL file back from FreeCAD using File → Export or using the instructions I provided in the previous article on how to get high quality STL files for 3D printing and then go 3D print your modified model.

Have fun building!!!

References

--

--