Gerber, BOM and Pick-and-Place: Every File a PCB Factory Needs
Every board house on earth reads the same small set of PCB manufacturing files. Gerber files describe the copper, solder mask and silkscreen one layer at a time. An Excellon drill file describes the holes. A BOM says which parts to buy. A pick-and-place file says where each part goes and how it is rotated. Get those four things right and your order sails through. Get one detail wrong — an open board outline, a drill file in the wrong units — and you get an email from a CAM engineer instead of a board.
This guide explains exactly what each file contains, what commonly breaks, and how a real order works from upload to shipment. If you are earlier in the process, start with how to make a PCB and come back here when you have a finished layout.
What Are Gerber Files?
A Gerber file is a plain-text, 2D vector description of one physical layer of your board. It is not a 3D model and it is not your design file — it is a set of drawing instructions: select this aperture (a shape of a given size), move to this coordinate, flash it or draw a line to the next coordinate. The factory's CAM software stacks those layers back up, and that stack becomes the photoplot for etching copper and printing mask and ink.
The format everyone actually uses is RS-274X, also called Extended Gerber. The important thing about RS-274X is that aperture definitions are embedded in the file itself. The obsolete RS-274D required a separate aperture list, and if someone hands you one of those, the board is essentially unmanufacturable without guessing. Modern EDA tools also emit Gerber X2, which adds attributes that label each file's purpose (top copper, bottom mask, and so on) so CAM software does not have to infer it from the filename. X2 is a superset — any factory that takes RS-274X takes it.
Because there is one file per layer, a Gerber "set" is a folder of files, and you upload it as a single ZIP. There is no universally enforced naming standard, which is why two conventions dominate: the old Protel extensions (.GTL, .GBL) and descriptive KiCad-style names (board-F_Cu.gbr). Both are accepted everywhere. What matters is that the set is complete and unambiguous.
The Complete Set of PCB Manufacturing Files
Here is every file in a typical two-layer order, what it holds, and whether you actually need it.
| Extension | KiCad layer | What it contains | Required? |
|---|---|---|---|
| .GTL | F.Cu | Top copper — traces, pads, pours | Yes |
| .GBL | B.Cu | Bottom copper | Yes |
| .G1, .G2 | In1.Cu, In2.Cu | Inner copper layers | 4-layer boards and up |
| .GTS | F.Mask | Top solder mask openings (where mask is removed) | Yes |
| .GBS | B.Mask | Bottom solder mask openings | Yes |
| .GTO | F.Silkscreen | Top legend — designators, logos, polarity marks | Strongly recommended |
| .GBO | B.Silkscreen | Bottom legend | Optional |
| .GKO or .GM1 | Edge.Cuts | Board outline — the shape that gets routed | Yes, critical |
| .GTP / .GBP | F.Paste / B.Paste | Solder paste apertures — used to cut a stencil | Only for stencils / assembly |
| .DRL or .TXT | — | Excellon drill file: hole coordinates and tool sizes | Yes |
| -NPTH.drl | — | Non-plated holes (mounting holes, tooling) | If your board has any |
| .gbrjob | — | Gerber job file: stackup, thickness, layer roles | Optional, helpful |
| BOM (.csv / .xlsx) | — | Which parts to buy, and how many | Assembly only |
| CPL / pick-and-place (.csv) | — | X, Y, side and rotation for every placed part | Assembly only |
The paste layers do nothing for a bare board. If you are ordering PCBs only and plan to hand-solder, you can leave them out — but include them if you want a stencil, because that is the file the stencil is cut from.
Drill Files Deserve Their Own Paragraph
Drill data is not Gerber. It is Excellon, a separate format with its own header. The header declares the units (metric or imperial) and the zero-suppression scheme, then a tool table assigns diameters to tool numbers (T01C0.300 means tool 1 is 0.3 mm), and the body lists coordinates under each tool.
Most tools split drilling into two files: PTH (plated-through holes — vias and component pins, walls copper-plated so they conduct) and NPTH (non-plated — mounting holes that must stay bare). Some factories want them merged, most accept them split. If your file has no explicit unit header, CAM has to assume, and an assumption of inches on a metric file produces holes 25.4× too small. Always export with the units stated.
The BOM: What to Buy
The bill of materials is the shopping list. For your own records it needs, at minimum, designator, quantity, value or part number, and footprint. For assembly it needs one more column that turns it from documentation into an order: a distributor part number the factory can actually source. For JLCPCB that is the LCSC "C" number (for example C25804 for a common 10 kΩ 0402 resistor).
A practical BOM for assembly looks like: Comment (the value), Designator (R1, R2, C5 — comma-separated when several parts share a line), Footprint, and LCSC Part #. Two things trip people up. First, distributor libraries split into cheap always-loaded parts and everything else — the second category usually carries a per-part setup fee, so consolidating on common values genuinely reduces cost. Second, a part that is in stock when you design may be out of stock when you order; check availability before you finalize.
Anything you do not want the factory to fit — a connector you will solder yourself, a part you already own — simply gets left off the BOM, or marked "do not populate."
The Pick-and-Place File (CPL)
The component placement list tells the assembly machine where every part goes. JLCPCB expects a CSV with these columns:
- Designator — must match the BOM exactly; this is the join key between the two files
- Mid X and Mid Y — the centroid of the footprint, with units (e.g.
12.7mm) - Layer — Top or Bottom
- Rotation — degrees counter-clockwise
Rotation is where assembly orders go wrong. Your EDA tool's idea of "0 degrees" for a footprint is not necessarily the supplier's idea of 0 degrees for the part on its reel. Polarized parts — diodes, electrolytic capacitors, LEDs, and especially SOT-23 and SOIC packages — end up soldered 180° out, and the board simply does not work. Two defenses: use the online placement preview the factory shows you after upload and visually confirm every polarized part, and consult the factory's published rotation reference for common packages.
The second classic CPL bug is the origin. Mid X and Mid Y must be measured from the same origin as your Gerbers. If you set a custom drill/place origin in your layout tool but exported Gerbers from the sheet origin, every part lands offset by the same amount. BuildPCB generates the Gerbers, drill files, BOM and a JLCPCB-format CPL from one source of truth, with a single shared origin, and zips the Gerbers ready to upload — which removes this particular failure mode entirely.
How to Order a PCB, Step by Step
The flow below is written around JLCPCB because it is the most common first order, but PCBWay, Seeed and the US houses work the same way.
- Export and zip. Gerbers plus drill files in one ZIP. No nested folders.
- Upload the ZIP. The site renders your board immediately. Look at it. This preview is your last cheap chance to catch a missing layer or a wrong outline.
- Set the build options. Layer count, board dimensions (auto-detected from the outline), quantity, thickness, mask colour, silkscreen colour, surface finish, copper weight.
- Choose bare board or assembly. A bare board (PCB) is copper and laminate only. Assembly (PCBA) means they buy and solder the parts. Assembly adds choices: which side to populate, and whether to add edge rails for small boards.
- Upload the BOM and the CPL separately. These are two more uploads, distinct from the Gerber ZIP. The site parses them and matches each designator to a stock part.
- Confirm parts and rotations. You get an interactive preview showing every component on the board. Fix any rotation or position here.
- Review the quote and check out. Engineering review happens after payment; expect a message within a day if something is unclear.
The Options That Matter
For a first prototype, the defaults are almost always right: 2 layers, 1.6 mm thick, 1 oz copper, HASL finish, green mask. Upgrade to ENIG if you have fine-pitch parts (0.5 mm pitch QFNs, BGAs) or need a flat, planar surface — it costs more but pads are flatter and shelf life is longer. Non-green mask colours can add a day. Heavier copper matters only if you are pushing real current.
Minimum order quantity for bare boards is typically five pieces, which is why "a run of five" is the universal prototype unit — you are not saving money by ordering fewer. Assembly minimums are usually lower but part procurement dominates the schedule. Realistically: a standard two-layer board is fabricated in about two to three working days, assembly adds several more days plus whatever time parts take to arrive, and then shipping to the US runs from a few days on express to a couple of weeks on economy.
Capabilities differ by factory and by process tier — minimum trace width and spacing, minimum drill size, annular ring, mask dam width, edge clearance. Read the manufacturer's own capability page before you finalize a tight layout, and set your design rules to match. Cheap tiers have looser limits than the premium ones at the same shop.
Checklist Before You Upload
- Board outline exists, is a single closed loop, and lives on its own layer
- DRC passes clean against the fabricator's rule set, not the software defaults
- Drill file declares its units in the header; PTH and NPTH both present
- Every copper layer exported — count the files against your layer stack
- Silkscreen does not sit on top of exposed pads
- Designators in the BOM match the CPL exactly, character for character
- Every assembled part has a valid, in-stock distributor part number
- Polarized parts checked for rotation in the online preview
- ZIP contains files at the top level, no subfolders, no stray PDFs or README files
What Commonly Gets an Order Rejected
Missing or open board outline. This is the number one rejection. If the outline layer is absent, or the shape has a hairline gap at a corner, CAM cannot determine where to route the board and the order stops. Two overlapping outlines are equally bad — the software cannot tell which one is real.
Wrong units in the drill file. A missing or incorrect Excellon header means holes come out 25.4× wrong, or coordinates land off the board. Always export with explicit metric or imperial declared.
Mask or silkscreen on the wrong layer. Exporting top silkscreen with a bottom-mask filename, or dumping fabrication and courtyard layers into the mechanical file the factory reads as the outline. Because there is no enforced naming standard, a mislabelled file is silently believed.
Parts outside the outline. A footprint or a reference designator sitting past the board edge in the CPL will be flagged, and on assembly orders it halts the job outright.
Empty solder mask layer. If the mask file has no apertures, the entire board is covered in mask and nothing is solderable. Rare, but it happens when a layer is exported without content.
Silkscreen over pads. Not usually a rejection — the factory clips it — but ink on a pad ruins the solder joint if it survives.
Getting the Set Right the First Time
None of this is conceptually hard; it is bookkeeping across a dozen files that must agree with each other. That is exactly the kind of work worth automating. BuildPCB produces the complete package from a description of the circuit — Gerbers and drill files zipped and ready, a BOM with sourceable part numbers, and a CPL in the format assembly houses expect — so the upload step becomes a review rather than a debugging session. You can read more about that approach in our guide to AI PCB design, or check the export details in the manual.
If you are still choosing tools, our roundup of PCB design software for beginners covers what each one exports and how painful the fabrication step is in practice. And the rest of the guides library walks through the stages before this one: schematic capture, layout, and design rules.
Frequently asked questions
What files do I need to manufacture a PCB?
For a bare board: a ZIP of Gerber files (one per layer, including the board outline) plus Excellon drill files. For assembly, add two separate uploads — a BOM with distributor part numbers, and a pick-and-place (CPL) file with each part's position, side and rotation.
What is the difference between a Gerber file and a drill file?
Gerbers are 2D vector drawings of each layer — copper, mask, silkscreen, outline — in RS-274X format. Drill files are a completely different format, Excellon, that lists hole coordinates and tool diameters. You need both; neither substitutes for the other.
Why does my board keep getting rejected for the outline?
The outline layer is either missing from the ZIP, drawn as an open shape with a small gap at a corner, or duplicated on two layers. It must be a single closed contour on its own layer, since it defines the physical shape the router cuts.
What are the JLCPCB pick-and-place file columns?
Designator, Mid X, Mid Y, Layer and Rotation. Coordinates must use the same origin as your Gerbers and include units, and the designators must match your BOM exactly, since that is how the two files are linked.
How long does a PCB order take and how many boards must I order?
Minimum order is typically five bare boards, which is why prototype runs are usually that size. A standard two-layer board is fabricated in roughly two to three working days; assembly adds several more days plus part sourcing, then shipping to the US ranges from a few days to a couple of weeks depending on the service.
Try it on your own board
Describe the board you need in plain words and BuildPCB designs it end to end — schematic, layout, checks and factory-ready files. It is in beta: review the result, and have a professional check anything complex before you manufacture.
Start designing