Skip to content
Tutorials Center
My learning

Topics

Lesson 2 of 36 ยท Getting Started

Install Unity and Create Your First Project

Install Unity Hub and the Unity Editor, pick a version and template, create your first project, and understand the folders Unity generates and what to keep in version control.

Before you can make anything, you need two programs: Unity Hub, a launcher that manages editor versions and projects, and the Unity Editor itself, the application where you build your game. This lesson walks through the install, the choice of project template, and the folders Unity creates, because knowing what is inside a project saves you from nasty surprises later.

Unity cannot run on this website, so the steps below are instructions for your own computer. The runnable examples at the end use plain C# to explore the project structure idea.

System requirements

Unity runs on Windows 10/11, macOS and several Linux distributions. In practice you want:

  • a 64-bit CPU and at least 8 GB of RAM (16 GB is much more comfortable),
  • a graphics card that supports DirectX 11/12, Metal or Vulkan,
  • 10 to 20 GB of free disk space for one editor version plus a few projects. Build support for other platforms (Android, iOS, WebGL) adds several GB each.

Check the official system requirements page for the exact numbers of your chosen version.

Step 1: install Unity Hub

  1. Download Unity Hub from the Unity website and run the installer.
  2. Sign in with a Unity ID (a free account). The Hub needs it to activate a license.
  3. Activate a Personal license if you are a hobbyist, student or small studio that qualifies. The Hub does this from the Preferences window.

Step 2: install an Editor version

In the Hub, open Installs and choose Install Editor. Pick the newest release marked LTS. During the install you can tick modules:

  • Microsoft Visual Studio Community (Windows/macOS) or use Visual Studio Code or JetBrains Rider as your code editor.
  • Android Build Support and iOS Build Support if you plan to publish to phones.
  • WebGL Build Support to publish to browsers.
  • Documentation if you want offline docs.

You can add modules later from the same screen, so do not worry about choosing everything now. Install only what you need to save disk space.

Step 3: create a project

Open Projects, click New project, then choose:

Choice What it means
Editor version The LTS you installed. A project remembers its version.
Template A starting point. Universal 3D (URP) for 3D games, Universal 2D for 2D, plus sample templates and VR/AR templates.
Project name and location Use a short folder path without strange symbols.

For this course choose Universal 3D for chapters 1 to 6, and a 2D template when you reach 2D workflows. The first open of a project takes several minutes because Unity imports and compiles everything.

If you are unsure, pick Universal 3D. You can still make 2D games in it: a 2D game is just a 3D scene viewed by an orthographic camera.

What Unity creates on disk

Look at your project folder in a file explorer. You will see:

TEXT
MyGame/
  Assets/            <- everything you make or import
  Packages/          <- manifest.json lists installed packages
  ProjectSettings/   <- physics, input, quality and other settings
  Library/           <- cache of imported assets (generated, huge)
  Temp/              <- scratch files while the editor runs
  Logs/
  UserSettings/      <- per-user editor layout
  MyGame.sln         <- generated code project files

Only three folders matter for version control: Assets, Packages and ProjectSettings. Everything else is rebuilt automatically. Library can grow to many gigabytes and must never be committed. Almost every Unity project has a .gitignore that excludes Library, Temp, Logs, UserSettings, build outputs and generated .csproj and .sln files.

Meta files

Next to every asset in Assets you will find a file with the extension .meta. It stores the asset's unique ID (GUID) and import settings. References between assets (a prefab using a material, a scene using a script) use these GUIDs. If you move or rename a file outside the editor and the .meta file does not move with it, Unity treats it as a new asset and every reference breaks. Always move assets inside the Project window, and always commit .meta files.

Step 4: open the project and check it works

When the editor opens you see a scene with a camera and a light. Press the Play button at the top center. Unity enters Play Mode, compiles any scripts, and shows the Game view. With an empty scene you see only the sky color; that is expected. Press Play again to stop.

Changes you make to a scene while Play Mode is active are thrown away when you stop. The editor tints itself (by default a slightly different color) to remind you. Make your real edits only when Play Mode is off.

Choosing a code editor

Unity opens scripts in an external editor. Choose it in Edit > Preferences > External Tools (on macOS, Unity > Settings). Visual Studio Community, Visual Studio Code with the C# Dev Kit, and JetBrains Rider all work; they give you autocomplete for the Unity API. Make sure the Unity package named Visual Studio Editor (or the matching package for your editor) is installed in the Package Manager.

Packages

Unity ships features as packages you add through Window > Package Manager: TextMeshPro, Cinemachine, Input System, 2D Sprite tools, ProBuilder, and many more. A package list lives in Packages/manifest.json, which is a small JSON file you commit. Two people who open the same project get the same package versions.

Runnable stand-in: reading a package manifest

The manifest.json is plain JSON. This stand-in parses a small manifest like the one in a real project and lists the dependencies, which is exactly what tools and CI scripts do.

C# Reading a manifest.json (stand-in)

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with Console.ReadLine()), it gets the next line from this box.

The version numbers here are only examples; your own project will list the versions of your editor release.

Runnable stand-in: what belongs in version control?

Here is a tiny filter that decides whether a path should be committed, using the rules from this lesson. Change the list of paths and see the result.

C# Which files go to Git? (stand-in)

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with Console.ReadLine()), it gets the next line from this box.

Common problems

  • Project opens with compile errors: usually a missing package or a script error. Open the Console (Ctrl+Shift+C) and read the first red message.
  • Hub says "No license": sign in again and activate a Personal license from Preferences.
  • Editor feels slow: keep the project on an SSD, and close unused Scene and Game panels while testing.
  • Pink objects: a material uses a shader from the wrong render pipeline. Use the template's pipeline consistently (see the editor tour).

Check your understanding

Quick check ยท 4 questions

of 4 answered You scored / 4 ยท perfect!

  1. 1. Which three folders must be under version control?

    Assets, Packages and ProjectSettings contain everything unique to your project. Library and Temp are generated caches.
  2. 2. What happens if you move an asset in File Explorer without its .meta file?

    The .meta file holds the asset's GUID. Without it, Unity generates a new GUID and every reference to the old one is lost.
  3. 3. What happens to scene edits made during Play Mode?

    Play Mode changes are temporary. Edit scenes while Play Mode is off, or copy a component's values before you stop.
  4. 4. Which template is a good default for a new 3D game?

    Universal 3D sets up the Universal Render Pipeline, which is the recommended starting point for most projects.

Summary

  • Install Unity Hub, sign in, activate a license, then install an LTS editor with only the modules you need.
  • Create projects from templates; Universal 3D is a safe default.
  • A project is Assets, Packages, ProjectSettings plus generated folders; commit only the first three and every .meta file.
  • Move and rename assets inside the editor, never in the file explorer.
  • Play Mode edits are temporary.

Next: Your First Scene