Course contentsShow
← Unity Game Development
Lesson 19 of 8281. Unity FoundationsFree lesson

Overriding Prefab Properties for Instance Variation

Learn to modify specific instances of a Prefab while maintaining a link to the original asset for efficient global updates.

In this lesson, you will learn how to customize individual instances of a Prefab without breaking the connection to your original template.

The Power of the Template

In the previous lesson, we learned that a Prefab acts as a blueprint. When you drag that Prefab into your Scene, you create an Instance. Usually, all instances follow the blueprint perfectly. But what if you have a "Tree" Prefab and you want one tree to be slightly taller, or a "Barrel" Prefab where one instance is a different color?

Unity allows you to modify an instance’s properties in the Inspector without affecting the original asset. These changes are called Overrides.

How to Override

When you select an instance in your Hierarchy, you will see its properties in the Inspector. If you change a value—like the Scale on the Transform component or the Color on a Material—you will notice a vertical blue bar appearing next to the modified property. This bar indicates that this specific instance has "overridden" the value defined in the original Prefab.

If you decide you don't like your change, you can click that blue bar and select Revert to snap the value back to the Prefab's default. Alternatively, if you find yourself liking a change so much that you want all your trees or barrels to look that way, you can click the Overrides dropdown menu at the top of the Inspector and select Apply All. This pushes your changes back into the original Prefab asset, instantly updating every other instance in your game.

Why This Matters

By using overrides, you maintain a "single source of truth." Your Prefab acts as the foundation, but your overrides provide the visual variety needed to make a game world feel organic rather than repetitive. You aren't creating new assets; you are simply applying unique adjustments to existing ones.

Key Takeaway: Overriding allows you to customize specific instances while keeping them linked to the original Prefab for global management.