Gerber X2 is the modern attribute extension to RS-274X Gerber. It keeps the same core image model that manufacturers already use, then adds structured metadata that explains what the image data means. Ucamco began adding the X2 attribute layer starting in 2014 (with the object and netlist attributes completed in the 2016 revision), and the older plain RS-274X image model is often described retroactively as X1.
The easiest way to understand X2 is to separate image from meaning. A normal RS-274X file can draw a shape perfectly, but a CAM system may not know whether the file is top copper, bottom solder mask, paste, or a mechanical drawing unless it trusts the filename or a layer map. Gerber X2 can embed that layer function directly in the file with attributes.
For background on the older format transition, see RS-274X versus RS-274D. To see how Gerber compares with richer package formats, jump to Gerber versus ODB++ versus IPC-2581.
Quick answer
Gerber X2 extends RS-274X by adding attributes. File attributes (%TF), aperture attributes (%TA), and object attributes (%TO) can identify layer function, pad type, vias, components, and nets. X2 is backward compatible because older RS-274X viewers can ignore those attributes and still render the image.
What attributes add
A Gerber layer is still a 2D vector image. It contains coordinates, draws, flashes, arcs, apertures, and regions that create the artwork. X2 attributes add labels to that artwork. They do not turn Gerber into the original editable PCB design database, but they help a receiving CAM system understand layer role and feature intent.
File attributes are written with %TF. They can identify the file function, such as top copper, bottom solder mask, top paste, or board profile. Aperture attributes are written with %TA. They can describe the purpose of an aperture, such as an SMD pad, via pad, component pad, fiducial, or other manufacturing feature. Object attributes are written with %TO. They can attach metadata to specific objects, including net, component, and pin information when exported by the tool.
Why X2 helps CAM intake
Traditional Gerber packages rely heavily on filenames, extensions, and readme files to identify layers. A file named board.GTL is probably top copper, but that conclusion comes from a naming convention, not the Gerber image itself. A generic .gbr file may be perfectly valid but ambiguous if the filename does not clearly describe the layer.
X2 reduces that ambiguity. CAM software can read the attribute and know that the file claims to be top copper or bottom solder mask. It can also use aperture and object attributes to support checks that are difficult with image-only data. For example, identifying SMD pads, vias, component pads, or net-related objects can help automate review and reduce manual layer mapping mistakes.
Attributes are not magic, and they are only as useful as the data the EDA tool exports and the CAM tool consumes. Still, they are valuable because they travel with the same Gerber layer image that the manufacturer already expects.
X1 vs X2 reference
| Topic | Gerber X1 / RS-274X | Gerber X2 |
|---|---|---|
| Layer image | Yes, self-contained RS-274X image data. | Yes, the same renderable image model. |
| Attributes | No structured X2 attributes. | Uses %TF, %TA, and %TO attributes. |
| Automatic layer identification | Depends on filename, extension, or layer map. | Can be embedded as file function metadata. |
| Object meaning | Mostly image-only. | Can carry pad, via, component, and net information. |
| Backward compatibility | Baseline format. | Older RS-274X tools can ignore attributes and render. |
| Adoption | Very common in modern PCB outputs. | Supported by many modern tools, but verify fab workflow. |
Backward compatibility matters
X2 was designed so that attributes do not break the basic image. If a tool only understands RS-274X image commands, it can ignore the X2 attribute blocks and still plot the shapes. That is important because PCB manufacturing involves many independent tools, scripts, and review systems. A useful Gerber extension must not make ordinary layer viewing fragile.
Backward compatibility also means X2 does not force a manufacturer to abandon existing Gerber flows. The fab can render the same layer image, and when its CAM software understands attributes, it can use the extra meaning for automation and checking.
What X2 does not replace
Gerber X2 is still Gerber. It does not replace Excellon drill files in ordinary PCB handoffs. It does not replace a bill of materials, pick-and-place data, assembly drawings, controlled impedance notes, or a full fabrication drawing. It can carry useful net and component-related metadata, but it should not be treated as a complete assembly package.
For a fabrication order, send the files your manufacturer asks for. In many workflows that means Gerber X2 layer files plus Excellon drills and a clear readme or drawing for stackup, thickness, finish, and special requirements. For assembly, you normally add BOM and placement files.
See X2 files in the viewer
Load your export ZIP in the Gerber viewer and confirm that the image renders as expected. Even when a viewer focuses on image rendering, an X2 file should still display like a normal RS-274X Gerber. Use the rendered view to catch missing layers, outline confusion, mirrored text, and drill alignment issues before the package goes to the manufacturer.
FAQ
- Is Gerber X2 backward compatible?
- Yes. A viewer or CAM tool that understands RS-274X but not X2 can ignore the attributes and still render the layer image.
- Does Gerber X2 replace Excellon drill files?
- No. X2 attributes add metadata to Gerber image files, but drill coordinates and tool sizes are still commonly supplied in Excellon drill files.
- What do %TF, %TA, and %TO mean?
- %TF defines file attributes, %TA defines aperture attributes, and %TO defines object attributes. Together they describe the meaning of Gerber data beyond the raw image.
- Should I export Gerber X2 if my CAD tool offers it?
- Usually yes, if your manufacturer accepts normal modern Gerber packages. X2 keeps the renderable image and adds useful metadata that can reduce layer-map ambiguity.