Using a PCB as a layout guide


I was just wondering:
I’m designing a system involving 2 stacked boards right now. A handy feature would be to use one of
the PCBs as a background for the new layout, for instance with partial transparency, with the ability
of switching it on and off. Is this possible?
I recently started to use FreeCad to draw a casing for my design, and it’s possible to add Kicad’s PCBs saved as step files. Doing this, I can fit the board directly in the case, and check whether the mechanical mounting holes of the case fit with the PCB. The same kind of feature would be very helpful. Is there anything similar in Kicad?


1 Like

I needed to make two boards with the same look but different parts. I exported the first board to a .step file. The opened up the second board and imported the .step file and saved it to a mechanical layer. Next I placed the connectors and large parts exactly on top of the old board (via the step layer).

I think that is close to what you want to do.


II like the idea too. I have old circuits and PCB designs in books and sometimes I wish I would be able to make a picture and use it as a pale background to create an identical, modern KiCad version. :camera:

Whats more, I could use pictures of housings and mechanical parts without having the full 3D models.

Hi, how to import step file in PCBnew?

I can only import dxf file.

In 5.99 (which is now 6.0RC1!) you can set transparency of 3D models for the 3D view.

As for “layout guide”, I’m not sure what you mean by that, but you can add shapes to some extra layer in one way or another and tune the layer transparency. If you tell more you can get more exact instructions.


Thanks for your reply. I have just tried, and the problem is that I cannot import a STEP file. I can export
step format and read it from FreeCad, but not from PCBNew.

I think that is close to what you want to do.

It even sounds like an exact match. So if you could be a bit more specific on how you import step files, it would greatly help me.

By the way, I’m using 5.99.(latest build), on Ubuntu21-10.


Why do you have to ask?
There is export and import of .DXF files, so you can generate a drawing and import them on one of the user layers. This is such a simple and logical way that I wonder why you have to ask.

If you have different PCB’s with the same outline / connectors, or other common features, then making a template from it may be a good idea. A “template” is just a KiCad project, with a bit of HTML added as a description of what it is for (so it can have embedded pictures, etc) and an icon so it has something that shows up among the other templates.


Because I don’t know how to do. I know how to export, as said earlier, but when I go to my new file
and try to import, I simply can’t.

  1. When exporting, I go to file->export, and in that submenu, there is a STEP menu item. If I choose
    this, I can export as step file that I can read from FreeCad, for example.By the way, there is no DXF submenu. Or in that menu DXF is not called DXF.

  2. When trying to import, I logically go to file->import. Then I can import 3 kind of things.
    Netlist: obviously not what I need
    Spectra session: I don’t know what it is, but doesn’t seem to be a STEP file.
    So I suppose this latter may do the job. The popup window says Import Vector Graphic files.
    In the supported format, bottom right of the popup, I can choose DXF or SVG, not STEP.
    And since I couldn’t export to DXF (see above), then… I’m stuck.

Ronsimson above says he’s able to import step files, so I must be missing something.

Thanks for any hint.

For the export, use: Pcbnew / File / Plot / Plot Format: DXF

This exports each layer to a separate file. You can edit, combine or modify those layers in some external program if you wish and then use **Pcbnew / File / Import Graphics to import the DXF file of your choice.

Oh, you don’t know how to add an extra 3D model to the board? You don’t add models to the board, you add them to footprints. You can add a “fake” footprint to the board which has only the 3D model.

Thanks for your reply. We get closer.

If you want to export DXF, don’t use the “export” menu, but the “plot” menu. Yes indeed, once you
know it, it’s simple and logic as long as you are tolerant with logic.

Somebody said above he can import step files.

Thanks anyway, it seems to import dxf. It’s late (22:30 here), I will check that tomorrow morning.

Thanks again!

In the loose sense of the word 3D models can be “imported” to footprints. In the sense used inside KiCad, 3D models aren’t imported. 3D models belong to footprints, and the word “import” isn’t used there.

A 3D model of a chassis can be used as a help when doing the design, but hardly for routing. What you actually want to use this “layout guide” for? How do you want it to help you?

Oh, don’t listen to that old fool. He talks with out thinking.
I had to convert to .DFX and then import to a layer like “DWGS.user”.
I just went back and tried again to probe it could be done. DFX!
You can import to PCB or you can import to a foot print and then bring that into a PCB.

I have a collection of boards that all plug into a mother board. I saved the board out line and connector locations so I could make all the boards exactly the same. (plot to .DFX) Then import it back in the next board.


Thanks for your replies, I could import a plotted file used as a background to the board I’m designing.

As I tried to explain above, the idea is to use one image of a motherboard as a background to one
daughterboard, in order to make sure that the connectors of the daughterboard will fit the motherboard.

Thanks anyway, it works.

Now if somebody has the same problem, here is a short summary.
In order to make DXF files of the board you want to use a background, there are a few details to be aware of in this process.

  • DXF files are not exported, but plotted. Plot is the tool you use to generate gerbers. Select
    DXF instead of gerbers and plot your board (file menu -> plot). As it is the same tool, it acts the same way. So don’t forget to create a dxf folder otherwise you will get files everywhere. Another way of doing this is to plot only the file you are interested in.
  • Careful with files like F_Cu, once you import them as a background of your new design, they can be extermely heavy. If the purpose is just to align the board so that the connectors face eachother, you might be interested in drill file only because you don’t need the traces. I just tried with the drill map file, and it does the job.
  • Once this is done, you can import the file in your new design, with file -> import -> graphics this time.

I have a collection of empty PCBs (Edge.Cuts + case info + important points marked at some User layer) for all cases I use. In one of those cases our product consists of 4 PCBs in paralel. Starting each of them from that empty case PCB gives me all important coordinates. If some are not important for single PCB I just delete extra lines.

…Back to the Original Question: “is there anything…

Answer: Yes

You can use the Tool (in the Main Panel) called “Bitmap To Component Converter” It works with other file types, too.

Here’s how:

• First, tweak your Photo to something clean and of descent quality
• If possible, best to know the DPI/Scaling used to generate it
• Run the Tool and Load your file
• Select the Picture Type and Adjust slider for desired quality
• Set the DPI as needed to get correct scaling (see below)
• Export to PCB - that makes a Footprint (.mod)
• Now, load the Footprint into your PCB and do your stuff with it

Note Scaling:
Photo’s/etc saved by Applications are at some DPI set by the Program and Computer settings - Thus, not consistent. You may need to Scale it (by setting the DPI in the Panel).

Commonsense (and some playing around) will dictate the correct DPI values.


I used an old PCB graphic (.png) exported in Fritzing, I loaded it in the Tool, adjusted as needed, dialed-in a DPI close enough for this show-and-tell. Then, dropped in two Parts ( Relay SW and Nano) and overlaid them on the image…

Also: You can load a photo with the PCB shape, do the same thing and edit the .mod file: change the Layer to Edge_Cut. That will give you a PCB shape…

Tweaking the original Photo can be as simple as using native tools on your machine and/or graphics programs - most have nifty tools for doing things like that…
Vid below shows doing it in Preview (Mac’s native Image viewer program) by changing Contrast, Exposure, Tint and Sharpness…etc




Thanks for your reply. And for the detailed howto. (for some reason, I need idiot-proof howtos).
Indeed it’s another interesting way to proceed. I’m thinking about another project where I have only
a drawing of some FPGA board. In this case, I could also use this if I make a proper scaling of the picture.

Right now, what I did is a copy of my motherboard project. I removed everything unrelated to the board
assembly itself (basically only mechanical mounting holes and the only connector remain). This way, I have a very lightweight dxf to import.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.