Disclaimer: Screenshots taken in a nightly from after the 5.0.0-rc2 tag. (KiCad 5 will look very similar but there will be slight differences in KiCad 4)
Other FAQ articles worth reading:
- What is the difference between footprints and symbols?
- How does KiCad know which symbol pin is connected to which pad of the footprint?
- Creating a new footprint library
- How to check footprint correctness?
- What is the meaning of the layers in pcb_new and in the footprint editor?
Other interesting resources:
- Import/Create FootPrint DXF (Designing a footprint using freecad and a background image)
- Freecad sketcher tutorial
Content of this Tutorial
The first part of this tutorial gives a short introduction to footprint design. It is followed by two example footprints. Direct links to these tutorials for your convenience.
- Creating a footprint from the manufacturer suggestion
- Creating a footprint without manufacturer suggestion
- Working with through hole (THT) parts
What is a footprint anyway?
A footprint describes the interface between the circuit board and the component it self. This is often called the land-pattern. At the least it needs to contain so called pads. It is also suggested to at least include the part outline and part identifiers (reference and value) on the silk and fab layers. Defining a courtyard area is also part of a good footprint.
The footprint name
Be careful when naming your footprint. Make sure you include enough information to clearly communicate what the footprint represents.
If a footprint is specialized for a single component then include the part number and the manufacturer name. For generic footprints include all identifying parameters. As a first step have a look at the footprint naming guide of the official library
Pads (The interface for soldering)
Pads are the representation of exposed copper features to which the leads of the component will be soldered.
Exposed copper means that in addition to defining the copper area the pad also needs to define a hole in the so called solder mask. Typically this cut-out is larger than the copper feature. This is achieved using the clearance settings. (In a typical footprint one sets it to 0 as this is normally handled in the pcb_new project settings.)
For through hole components there is also the drill defined.
In addition the pad number must also be set to allow the connection between footprint and symbol (between schematic and layout)
An exception are non plated through holes. These define only a drill size. (No pad number, no copper)
The silkscreen (Documentation printed onto the board)
The silkscreen is what will be printed onto the board. The colour of it will most likely be white. One can put anything onto it. It is however typical to include the outline of the component, the reference and a polarity marker. This highly depends on your preferences, the space available and on your manufacturers restrictions.
The outline is normally drawn outside the nominal dimensions of the part. It should also not overlap any exposed copper features (Keep it away from pads)
For small smd parts one needs to take care not to include silkscreen below the part itself, as it can increase the probability of soldering problems. (Example tombstoning)
If this is not a concern in your particular application then you can also include silk under the part to aid manual assembly. (Especially useful for through hole connectors. Can make it easier to know the insertion direction.)
The fab (fabrication) layer (Technical documentation for manufacturing and maintenance)
The fabrication documentation layer does not directly interact with the pcb. It will most likely only be used as documentation for assembly or for maintenance. It can also be very helpful during the pcb design process. Typically it contains the outline of the part. (Exact dimensions are preferable.)
Including the reference and value field plus a polarity marker makes this layer a lot more useful. (Text sizes can be decreased compared to the silk layer as we do not need to take care of manufacturing constrains. This allows putting the reference inside the part outlines -> less clutter while layouting the board.)
The courtyard (keepout area for other parts to allow for assembly)
The courtyard area defines a keepout for other parts. This is used to communicate the space needed for assembly and soldering. How much space is required depends on which assembly process is used. The space required for hand soldering is much larger than for reflow soldering. Manual placement also has different requirements when compared to automatic placement using a pick and place machine.
Since version 5 courtyard overlap is checked by DRC. For this to work the drawing must be a closed polygon. (Endpoints of neighbouring features must be within 0.01mm)
Creating a footprint using the footprint editor
All elements of a footprint are specified relative to the footprint origin. This means pads are defined via their center point relative to that origin plus size specifiers.
To create a footprint the first step is to translate dimensions given in the datasheet into a form that gives the center position and size of pads. (Relative to the chosen center)
What center should be chosen for the footprint?
If your footprint is intended only to be used by yourself and you hand populate the pcb, then you can put the center anywhere you want. (Make it easy for your self. We will get back to that later on.)
Center point for automatic assembly
If the pick and place center position is given in the datasheet then use that.
For surface mounted components (SMD) the center of the part body will be a good choice for the footprint center.
For through hole parts (THT) typically pin 1 is chosen as the center position.
Something important to keep in mind: If you plan on having your board assembled by a machine, talk to the guys programming it. They can give you guidance.
Getting dimensions for the footprint
Disclaimer: This section might go into too much depths for a novice. Especially the later subsections. In practice eyeballing the dimensions should be ok for a lot of use-cases. Especially true if the part is hand-soldered. It might still be a good idea to read this as it might give you inspiration for how to improve your skills.
What can be expected inside a datasheet
Every good datasheet at least contains a detailed dimensioned drawing of the component. Some even contain a suggested footprint layout to give the user a starting point.
Such a suggested footprint should not be taken at face value. Especially older datasheets might be out of date with current manufacturing methods and industry standards. (Meaning if you have access to some reliable piece of information that contradicts the suggested footprint, it might just be that the datasheet is wrong.)
The dimensioned drawings are most likely found somewhere near the end of the datasheet. (Not all datasheets follow that rule. I have encountered datasheets where the packaging information is somewhere in the middle.)
Some manufacturers do not include the dimensioned drawings in the datasheet but have them in a separate document.
What to do if datasheet does not give a suggested footprint?
If a datasheet does not contain a suggested footprint, it is possible that the manufacturer supplies an application note that aids the user in creating a valid footprint. Dimensioned drawings of footprints in such application notes do not necessarily apply to the component in question. (Application notes might be written with many different components in mind. Drawings might just be examples for some of them.)
Some conclusions can still be drawn from the application note even if it is not for the exact part you are using.
Another source for information are similar footprints from a trusted source. In most cases it is easier to modify such a footprint than to create one from scratch.
Datasheets of similar parts by other manufacturers can also supply some useful information. Especially if they contain both a dimensioned drawing of a footprint and the package. If the dimensioned drawing of the package is the same as your component then you can use the footprint as is. Otherwise you can use it to get information about fillet sizes. (More details in the example about the qfn footprint below.)
Some manufacturers also have a specialized tool with its own specialized file format to share footprints with their users. (Analog devices is an example for that. Sadly their tool only runs under windows. It also requires you to register with them. At least at the time of writing this.)
Using industry standards
Industry standards can be of great help when designing a footprint. Sadly such standards are most likely closed. (They are quite expensive.) One well known standard for smd parts is the IPC-7351 series. (IPC-7351B is the most recent standard at the time of writing. IPC-7315C is expected to be released soon.)
There exist tools that generate footprints in accordance to IPC standards. All of them however are closed and cost quite a bit. (If you really worry about being complaint this will be the price to pay.)
There are some open tools out there (Example: The python footprint generator for kicad has some ipc generators The QEDA project also has some IPC footprint generators.). Such tools are not able to give you a certificate for your parts.
We will discuss the terminology used in this standards later on. We will also design a footprint using some of the more easily to find recommendations. (With some patience a surprising amount of information about this standard can be found.) Older IPC standards can even be found complete on some file sharing sites. Be aware that sharing them would be a violation of copyright. (This is why we will not link to any such documents here.)
Talk to your manufacturer
If you know which manufacturers will be used to produce your PCB and also who will be used to solder it, you might want to ask them for their “Design for Manufacturing” (DFM) guidelines. These guidelines might contradict other industry standards. (Like with every other competing set of standards.) Use your own judgment what guideline to trust. (If it is critical it might pay to produce some sample pcbs and analyze the result.)