I am using Unity 2022.3. Every shader graph asset has a material subasset. It has the same name as the shader. I do not want to have those materials in my project.
I understand the reasons behind these materials: they provide a base so that other materials can be variants of it, thus inheriting the default values defined inside the shader graph. However, I do not want that functionality in my project. I want to reduce the possibility of human error by selecting wrong materials.
I would have expected this new feature to be a toggleable setting, but it is not. Is there any place where these materials can be stopped from being auto-generated?

6 Likes
Yes, this is just uselessly polluting my project and searches
Apologizes if I’m responding to a too old thread, but it showed up in my google search, so maybe this helps someone who found it the same way.
There is a way to do it, it’s not super convenient but it works. While Unity is not running, copy the Shader Graph package from the package cache into your project’s own Packages folder, then open your project again. This allows you to make custom modifications to Shader Graph.
Next, open ShaderGraphImporter.cs and comment out the following two lines:
//Material material = new Material(shader) { name = primaryShaderName };
//importContext.AddObjectToAsset("Material", material);
Downside is, you need to redo this every time you update Shader Graph. But for now, I think this is the best solution we have and the one I currently use.
1 Like
It is a good workaround, thank you!
Off topic:
Are you the Nifflas? Creator of Within a Deep Forest, Knytt, Saira… If so, just know that your work shaped my taste for video games 
1 Like
I am!
I’m very happy to hear it!
1 Like