Shadergraph 2D Sprite Transparency not working

I’m experimenting with ShaderGraph and can’t get the transparency to work. I have looked everywhere and can’t find an answer. I have some sprites with transparent backgrounds which show up perfectly when just dragged and dropped into the project, but when using the ShaderGraph material it produces the sprite with a weird blocky blue background around the sprite.

And here’s a Shadergraph sprite vs a normal dragged in sprite.

I imported the RenderingPipeline into the project and created a 2d renderer while also making these Unity’s defaults, so I’m not sure what’s going on. Anyone know how I can get a shadergraph material to display a 2D sprite correctly?

you have to connect the A(1) dot from Sample Texture 2D to Fragment Alpha( 1) ,You have to connect the A(1) dot from Sample Texture 2D to Fragment Alpha( 1)

1 Like

I think you need to input the alpha channel from your SampleTexture2D output into the alpha channel on your Fragment input.

Change Surface type to transparent from graph setting(graph inspector) and also connect sample texture 2d (a1) to fragment (a1) alpha