What Is A Gerber File: One Layer, Not One Design
A Gerber file draws one layer of a board. It is not the design.
That single sentence explains most of the confusion. People expect one file that opens into a board. What they get is a folder of a dozen files, each drawing one layer.
Every board house on the planet reads this format. It is open, it is plain ASCII, and it has been the industry default for decades.
This page covers what the files contain, which set a factory needs, and the one that is most often missing when an order stalls.
What The File Actually Is
The Gerber format is an open vector image format. Each file holds a stream of commands that draw pads, tracks and regions on one layer.
It is not a design database. There are no components, no schematic links and, by default, no netlist inside it.
The files come out of the design software at the end of the job. That step is usually called CAM output. That step turns a design into pictures a machine can print.
Bare board shops load those pictures into their own software, then prepare tooling for drilling, imaging and plating. From there the format is read by plotters, direct imagers and inspection machines.
Who Actually Reads These Files
It helps to know that the reader is a machine, not a person. Several machines, in fact.
A plotter or a direct imager turns the layer into an image on the board. A legend printer does the same for text. An inspection camera compares what came out against the file.
Each of those reads the same format, which is why it survived. A format only one vendor could read would have died with that vendor.
Assembly reads it too. Paste layers drive the stencil, and a separate file of component centres drives the placement machine.
That last file is the second one people forget. Every part needs an X and a Y, a rotation and a package name, and none of that lives in a copper layer.
Two Generations, One Revoked
The format is named after Joseph Gerber, whose company built the vector plotters that drew boards photographically. The first edition of the format dates from 1980.
The old version had two weaknesses that are worth knowing, because they still show up as bad habits.
Its coordinate unit and its aperture shapes were not in the file. They lived in a sidecar text file with no standard, so sender and receiver had to agree on meanings case by case.
It also could only draw lines and flash simple shapes. Solid copper had to be painted with thousands of strokes, which made huge files and slow, error prone work.
Extended Gerber, also called RS-274X, arrived in 1998 and fixed both. It carries its own aperture definitions, so one file is enough, and it can describe a plane or a pad directly.
The old format was formally revoked in 2014. If a supplier’s output needs a separate aperture wheel file, the tool chain is decades behind.
The specification is now kept by the company that maintains it, which publishes the document, test files and a reference viewer. That is why the current revision carries a year and a month rather than a version number.
Inside The ASCII
A modern file is readable. The commands are short, and each one has a job.
A file starts with tags that name what it draws. One line might read %TF.FileFunction,Copper,Bot,L4*%, which says this is copper, bottom side, layer four.
Then come the format and unit lines. %FSLAX36Y36*% sets the coordinate format, and %MOMM*% sets millimetres.
Apertures are defined with D-codes. %ADD10C,0.15000*% defines shape ten as a circle of 0.15 mm, which is a track width in most files.
Then the drawing commands follow. D02 moves without drawing, D01 draws a line to the new point, and D03 flashes the current aperture as a pad.
The file ends with M02. Four letters, and the machine knows the layer is complete.
You do not need to read these files by hand. You do need to know they exist, because a viewer that shows a blank layer is usually reading a file whose function line is wrong.
The Layer Set A Board House Needs
A quote request that arrives with one copper layer and nothing else will go back as a question. The factory needs a set.
| File | What it draws | What happens without it |
|---|---|---|
| Copper, one per layer | Tracks, pads and planes | Nothing to etch |
| Soldermask, top and bottom | The openings over pads | The whole board gets covered |
| Legend or silkscreen | Text, outlines, pin one marks | Assembly has no reference marks |
| Paste, top and bottom | Where the stencil prints | No stencil, and assembly stops |
| Profile | The board outline itself | Not a complete set, and routing is guesswork |
| Drill | Every hole and its size | The order stalls at the drill step |
| Job file | Finish, thickness, stackup | Someone guesses the surface finish |
Two rows in that table surprise people. The profile layer is not optional, because the rules ask for an outline, and a set without one is incomplete.
The paste layers are only needed for assembly, not for the bare board. A board house quoting bare boards may not care, and the assembly house will care very much.
All layers must also be aligned to each other. A stack that is offset by a millimetre looks fine in a viewer and is obvious at the drill.
The Placement File
Bare board shops need the images and the holes. Assembly houses need one more thing: where the parts go.
That data is usually a spreadsheet or a text file listing each reference, its X and Y position, its rotation and its package.
It is not a Gerber layer, and it is not in the drill file. It comes from the placement side of the design software.
Two small failures show up here often. A rotation off by ninety degrees, and a reference designator that changed after the file was exported.
Both are visible in a first article. Both cost a day if nobody looks until the run is finished.
The Drill File That Stops An Order
Drill data has its own history. For reasons nobody defends today, holes were sent in NC formats, and Excellon became the common one.
So a complete submission usually carries two formats: Gerber for the images, Excellon for the holes.
That split is where orders stall. The drill file can be missing. It can also describe a hole pattern that no longer matches the pads.
A pad with no hole, or a hole with no pad, is the kind of mismatch a fabricator spots at once. A designer does not see it in a viewer.
The audit step before release exists for exactly this. The usual checks are missing or duplicated layers, drill data that disagrees with the images, and files from an older revision of the design.
If the answer to “is the drill included” is a pause, stop and fix it before paying. Every later step assumes the holes.
Attributes: X1, X2 And X3
The format has grown three times without changing what it draws. The additions are all detail about the drawing.
| Generation | What it adds | Why a buyer cares |
|---|---|---|
| X1 | Graphics only | The factory guesses which file is which |
| X2, from 2014 | File function, part, pad function | Layers load without a human |
| X3, from 2020 | Further build detail | Fewer questions before tooling |
The most useful attribute is the file function, because it removes the guessing. It names the layer in words the software understands.
Pad function is the quiet one. It tells the software which flashes are component pads, which are vias, and which are fiducials, which is what automated front end tools need.
Without attributes, people encode layers in file extensions. A file called something .BOT is a common sight, and the industry treats it as poor practice rather than a convention.
Ask which version your designer exports. It costs nothing to choose X2 and saves a round of questions at the factory.
What Gerber Cannot Say
Three things a board needs are not images, so they live outside the layer files.
The first is the build itself: the stackup, the copper weight, the overall thickness and the surface finish. These sit in a Gerber Job File, a small companion file with its own extension.
The second is the netlist, if the factory is going to test the board electrically. It can be embedded, or sent as a separate file in the older test format.
The third is anything the two of you agreed in words: an impedance target, a colour, a tolerance, a date code. Written notes beat a clever file every time.
A package with images, holes and a job file is complete. A package with images only is a conversation.
What A Gerber File Is Not
It is worth saying plainly what the format does not carry, because buyers often assume it carries it all.
It does not hold components. A part exists in the design database, not in the layer images, which only see its pads.
It does not hold the rules you designed to. A clearance, an impedance target or a controlled depth lives in your notes or your design software.
It does not prove the board works. A perfect stack of layers can describe a circuit that will not work, because the mistake happened before export.
That last point explains a habit of good fabricators. They check the data they receive rather than trusting it, then come back with questions before cutting anything.
What A Good Package Looks Like
The folder itself carries detail. A clean package needs no explanation, and a messy one always needs a phone call.
Put it all in one archive. Name the archive with the board name and the revision.
Give the files names a stranger can follow, and let the attributes do the formal work. If you use X2, the file names matter far less.
Add a one page note with the stackup, the finish and the thickness. That note is what stops a factory guessing at the surface finish.
Last, say which revision you are approving. A folder called final, and another called final2, is how two revisions end up in one order.
Three Checks Before You Send
The audit takes minutes and saves a week. Open the package in a viewer and look at three things.
First, do all layers line up? Pick one pad and follow it through copper, mask and paste. An offset shows up here and nowhere else.
Second, is there an outline? A set without a profile layer is incomplete by the rules, and the factory will have to invent one.
Third, is the date on the files the date of this design? Old files in a new folder are common, and they are the reason a batch comes back with a change nobody asked for.
Then compare the drill against the copper one more time. Every pad that should have a hole should have one, and every hole should land inside a pad.
Six Lines for the Order
Put these in the message that carries the package.
One. The layer count and the stackup, written out, not implied by the file names.
Two. The surface finish, because the job file may not be read by everybody.
Three. Copper weight and the finished thickness, with the tolerance you will accept.
Four. Any impedance target, with the layer it applies to.
Five. The file version you exported, so the factory knows whether attributes are available.
Six. Which revision you are approving, in words and as a date.
Three reads help at this point. The run that builds the first boards covers what happens after the bare board arrives.
How the paste and the oven turn that board into an assembly is the next process in line.
And The brief that comes back in one shape is the format that gets all six lines answered together. For the inspection step afterwards, the check that happens once the board exists is where a data mistake finally shows.
Send me the file list from your fabrication package, or the zip itself if it is small. I will tell you which layers are missing and whether the drill matches the copper. Then I list the questions the factory will ask.
Check The PackageQuestions Buyers Ask
Is a Gerber file the same as a PCB design file?
No. A design file holds components, nets and rules. A Gerber file holds one layer of the image, which is what a machine needs to build the board.
Why are there so many files in the zip?
Because each layer is its own file. One board may need copper, mask, legend, paste, an outline and drill data, plus a job file for the build details.
What is usually missing from a package?
The drill file, surprisingly often. Drill data travels in a separate NC format, so it is easy to leave out and easy to let drift out of step with the copper pads.
What is the difference between X1 and X2?
Tags. X2 files name the layer function, the part and the pad types, which lets the factory load layers without a human instead of guessing from file names.
Can the factory work from the files alone?
Not for all of it. Stackup, finish and thickness sit in a job file or your notes, and impedance or tolerance agreements are words, not images.
Should I send a viewer file too?
It helps. The layer stack is what gets fabricated, and a picture of the finished board is the fastest way to show the factory what you think you sent.
Questions & Comments
We read every one and reply within 24 hoursIf a factory has asked you for a file you have never heard of, send me the list they sent. It is usually a drill file or a job file.