Version: Unity 6 Preview (6000.0)
Language : English
Set the render queue of a shader
Prioritize lower quality shaders with the LOD command

Set when Unity runs a shader pass via a LightMode tag

The LightMode tag is a predefined Pass tag that Unity uses to determine whether to execute the Pass during a given frame, when during the frame Unity executes the Pass, and what Unity does with the output.

Note: The LightMode tag is not related to the LightMode enum, which relates to lighting.

Every render pipelineA series of operations that take the contents of a Scene, and displays them on a screen. Unity lets you choose from pre-built render pipelines, or write your own. More info
See in Glossary
uses the LightMode tag, but the predefined values and their meanings vary. For more information, see Syntax and valid values.

In the Built-in Render Pipeline, if you do not set a LightMode tag, Unity renders the Pass without any lighting or shadows; this essentially the same as having a LightMode value of Always. In the Scriptable Render Pipeline, you can use the SRPDefaultUnlit value to reference Passes without a LightMode tag.

Example in a Shader block

Shader "Examples/ExampleLightMode"
{
    SubShader
    {
        Pass
        {    
              Tags { "LightMode" = "Always" }
            
              // The rest of the code that defines the Pass goes here.
        }
    }
}

Example in a SubShader block

Shader "Examples/ExampleLightMode"
{
    SubShader
    {
        Pass
        {
            Tags { "LightMode" = "Always" }
            // The rest of the code that defines the Pass goes here.
        }
    }
}

Additional resources

Set the render queue of a shader
Prioritize lower quality shaders with the LOD command