> ## Documentation Index
> Fetch the complete documentation index at: https://docs.deeppcb.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Via Definitions

> Create a via definition in DeepPCB by asking Cooper for it, and attach it to a net class.

A via definition is a named via geometry — pad and hole size, and the layers it spans. Net classes reference a via definition, so the engine knows which via to use for which nets.

## Attach a Via Definition to a Net Class

1. Click **Setup** at the top of the board editor, then **Net Classes** under **Nets**.
2. Click the edit button at the end of the net class's row. **Edit Net Class** opens.
3. Under **Via Definition**, pick the definition the class should use.
4. Click **Apply**.

The table's **Via Definition** column shows the class's new via.

<video autoPlay muted loop playsInline src="https://mintcdn.com/deeppcb/4U0o544YQLW2m18K/images/how-to/via-definitions.mp4?fit=max&auto=format&n=4U0o544YQLW2m18K&q=85&s=7d6253ab44533ff4cfa475597b8745a4" />

Switching the SPI net class to the Via\[0-3]\_0.4:0.2mm via definition, then Apply.

The same dialog sets the class's **Clearance** and **Track Width**, and the nets that belong to it. See [Board Setup](https://docs.deeppcb.com/guides/board-setup.md).

## Ask Cooper for One

Cooper creates a via definition and assigns it to a net class in one step. Tell it the class, the pad and hole size, and the layers the via should span — for example, *Create a via definition for the SPI net class: 0.6 mm pad, 0.3 mm hole, through all layers*. The change is made as soon as Cooper answers; there is nothing to accept or apply.

See [Create a Via Definition](https://docs.deeppcb.com/tutorials/how-to/cooper/via-definition.md) for what Cooper asks for if you leave something out, and how to check the result.

> [!NOTE]
>
> Via definitions normally arrive with your board file, from the via rules set in your EDA tool. DeepPCB supports through, blind, buried, and at-SMD vias — see [Routing](https://docs.deeppcb.com/guides/routing.md) for which via types the engine will place and when.

> [!TIP]
>
> A net class can also carry an ordered list of via configurations — prefer a blind via, fall back to through-hole — set in the board file; see [Vias](https://docs.deeppcb.com/guides/routing.md#vias).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.