# Manage GameObjects in the Hierarchy window

> Use the Hierarchy window to create and organize GameObjects and control their visibility in a scene.

Use the **Hierarchy** window to create and organize GameObjects and control their visibility in a scene.

The **Hierarchy** window displays every [GameObject](/engine/6000.5/manual/working-with-gameobjects/game-objects.md.md) in a scene, including models, cameras, and [prefabs](/engine/6000.5/manual/working-with-gameobjects/prefabs.md.md). You can use the **Hierarchy** window to manage and group the GameObjects you use in a scene. When you add or remove GameObjects in the Editor view, you also add or remove them from the **Hierarchy** window.


**The default Hierarchy window when you open a new Unity project:**
![](/api/media?file=/engine/6000.5/media/images/hierarchy-window.png)

The **Hierarchy** window can also display other scenes, with each scene containing its own GameObjects. You can have more than one scene open in the **Hierarchy** window at the same time. For more information, refer to [Work with multiple scenes in Unity](/engine/6000.5/manual/working-with-scenes/multi-scene-editing.md).

## Create a new GameObject

To create a new GameObject in the **Hierarchy** window:

1. Right-click on empty space in the **Hierarchy** window under your selected scene.
2. Select the GameObject you want to create from the context menu.

You can also use the keyboard shortcut **Ctrl**+**Shift**+**N** (macOS: **Cmd**+**Shift**+**N**) to create a new empty GameObject.

> **Note:**
>
> By default, Unity creates new GameObjects in rename mode. To disable this behavior, open the **More** (**⋮**) menu in the **Hierarchy** window and deselect **Rename New Objects**.

## Duplicate a GameObject

To duplicate a GameObject, right-click the target GameObject and select **Duplicate**.

You can also use the keyboard shortcut **Ctrl**+**D** (macOS: **Cmd**+**D**) to duplicate the selected GameObject.

## Reorder items in the Hierarchy window

By default, the **Hierarchy** window lists GameObjects by order of creation, with the most recently created GameObjects at the bottom. You can reorder the GameObjects by dragging them up or down.

## Group items using parenting

Unity uses the concept of parent-child hierarchies, or parenting, to group GameObjects. A GameObject can contain other GameObjects that inherit some of its properties. Child GameObjects inherit the movement and rotation of the parent GameObject. To learn more, refer to [Transform component](/engine/6000.5/manual/working-with-gameobjects/gameobject-fundamentals/class-transform.md).

You can link GameObjects together to help move, scale, or transform a collection of GameObjects. When you move the top-level GameObject, or parent GameObject, you also move all child GameObjects.

To group items into a parent-child hierarchy, select the child object and drag it onto the parent object. To ungroup items, select the child object and drag it to a different position in the **Hierarchy** window.

You can also create nested parent-child GameObjects. All nested objects are still descendants of the original parent GameObject, or root GameObject.

To set parent-child relationships in a C# script, use the [`Transform.SetParent`](/engine/6000.5/script-reference/unityengine/transform/setparent.md) method or the [`Transform.parent`](/engine/6000.5/script-reference/unityengine/transform/parent.md) property of the child GameObject.


**Child 1 and Child 2 are the child GameObjects of Parent. Child 3 is a child GameObject of Child 2, and a descendant GameObject of Parent.:**
![](/api/media?file=/engine/6000.5/media/images/parenting-in-hierarchy-window.png)

### Create a child GameObject

To create a child GameObject, drag it onto another GameObject in the **Hierarchy** window.

### Paste GameObjects as child

You can cut or copy a selected GameObject and then paste it as a child of another GameObject. Pasted child GameObjects keep their world position.

To paste a GameObject as child:

1. Right-click the selected GameObject, and then select **Cut** or **Copy**.
2. Right-click the intended parent GameObject, and then select **Paste as Child**.

You can also press **Ctrl**+**Shift**+**V** (macOS: **Cmd**+**Shift**+**V**) to paste a GameObject as a child.

### Create a parent GameObject

You can add a new GameObject into the **Hierarchy** window as the parent of existing GameObjects.

To create a parent GameObject:

1. Right-click a GameObject, or select multiple GameObjects on the same level and right-click.
2. Select **Create Empty Parent**.

You can also use the keyboard shortcut **Ctrl**+**Shift**+**G** (macOS: **Cmd**+**Shift**+**G**) to create a parent GameObject when you have selected a GameObject.

## Show or hide child GameObjects in the Hierarchy window

In the **Hierarchy** window, you can toggle the visibility of child GameObjects in the following ways:

* Select the foldout arrow (►) to the left of the parent GameObject to expand it.
* Hold **Alt** while clicking the foldout arrow (►) to toggle visibility of all descendant GameObjects of the root GameObject.
* Select the drop-down arrow (▼) to collapse all descendant GameObjects.

## Organize GameObjects with default parent

You can make any GameObject in the **Hierarchy** window the default parent. When you create a new GameObject, or drag a GameObject into the Editor view, Unity automatically makes this GameObject a child of the default parent GameObject.

To set a GameObject as the default parent:

1. In the **Hierarchy** window, right-click on the GameObject.
2. Select **Set as Default Parent**.

The name of the default parent GameObject in the **Hierarchy** window is bold.

To remove default parent status from a GameObject:

1. In the **Hierarchy** window, right-click on the GameObject.
2. Select **Clear Default Parent**.

You can only set one default parent per scene. In the **Hierarchy** window, if you set a GameObject as the default parent, and then you make a different GameObject in the same scene the default parent, only the second GameObject is the default parent.

If you have multiple scenes in the **Hierarchy** window, and you set default parents in each scene, when you drag a GameObject into the **Scene** view, Unity makes the default parent GameObject in the active scene the parent of the new GameObject.

You can set a keyboard shortcut for the default parent setting in the [Shortcuts manager](/engine/6000.5/manual/unity-editor/editor-navigating-managing/shortcuts-manager.md). On the Shortcuts window, assign a keyboard shortcut to **Hierarchy View** > **Set as Default Parent**. If there's no default parent set, and in the **Hierarchy** window you select a GameObject, use the shortcut to make this GameObject the default parent. When a default parent is set, use the shortcut to remove default parent status from any GameObject that has it.

## Set Scene visibility and pickability

If you have a scene with many GameObjects, it can be difficult to find and select specific GameObjects in the [**Scene** view](/engine/6000.5/manual/unity-editor/editor-windows-views-reference/using-the-scene-view.md). To clear the **Scene** view without impacting the visibility or behavior of GameObjects in the game, you can toggle the visibility and pickability of GameObjects from the **Hierarchy** window:

* To hide and show the GameObject, select **Scene visibility** (eye icon).
* To toggle the GameObject's pickability, select **Scene picking** (hand icon).

> **Note:**
>
> If you select multiple GameObjects, press **H** to hide and show them, and **L** to toggle their pickability.

For more information, refer to [Scene visibility](/engine/6000.5/manual/working-with-scenes/scenes-manage-gameobjects/scene-visibility.md) and [Scene picking](/engine/6000.5/manual/working-with-scenes/scenes-manage-gameobjects/scene-picking.md).

## Additional resources

* [Hierarchy window reference](/engine/6000.5/manual/unity-editor/editor-windows-views-reference/hierarchy-window/hierarchy-reference.md)
* [GameObject class](/engine/6000.5/manual/working-with-gameobjects/gameobject-fundamentals/class-game-object.md)
* [Scene view](/engine/6000.5/manual/unity-editor/editor-windows-views-reference/using-the-scene-view.md)
* [Inspector window](/engine/6000.5/manual/unity-editor/editor-windows-views-reference/using-the-inspector.md)
