Subgraphs are a collection of Shader Graph nodes that can be easily reused as a single node across other Shaders and even other Subgraphs. This is an easy way of develop custom Shader Graph Functions of your own.

Creating a Subgraph

You can create an empty Shader Graph Function by creating a new Asset and selecting Shader -> Shader Graph Function

Creating an empty Subgraph

You can also create a Shader Graph Function from pre-existing nodes in a graph by selecting them all, right clicking, and selecting "Create Custom Node"

Right clicking on pre-existing nodes to create a Subgraph from them

Subgraph Properties

When no nodes are selected, you can edit the properties of the Subgraph itself, including it's Name, Description, Icon, and whether or not it should appear in the Node Library (If not, the node will not appear in the right click menu or the Palette)

The Subgraph Properties The Custom Node appears when added to the Node Library

Creating Outputs

Every Subgraph has a "Result" node, which is similar to the "Material" output node from regular Shader Graphs. However in a Subgraph you can define as many outputs as you want via the Properties panel, and can even choose which outputs to display in the Preview tab.

The Output as seen on the Custom Node

Creating Inputs

Any Constant nodes that are used in a Subgraph will be baked into the subgraph as a constant value unless it is given a Name. Any named constants will automatically have their inputs exposed on the left side of the node, with the set value as the given default.

A Color constant is named "Tint", while a Float constant is named "Intensity"

The Inputs as seen on the Custom Node (with their default values)

Setting "Is Required Input" to true on a Constant node will prevent the user from being able to set the default value, instead requiring them to connect the output of another node.

Using Textures

Any Texture nodes that are used in a Subgraph MUST be named in order to compile, as they cannot (currently) be baked with the shader. This is because any Material made using this shader needs to define any Textures used, and whoever is using your shader might not have the referenced Texture.

When using a Subgraph Node, the default Texture can be changed via the Properties tab, alongside the unrequired Inputs.

The default Texture property exposed in the Properties tab when the Custom Node is selected






Created 20 Aug 2025
Updated 20 Aug 2025