Chapter 2: Setting Up Your Development Environment

setting up your dev environment and seeing your first app run on a phone (or emulator). Let’s do this like we’re side-by-side in Airoli, me guiding you on your laptop while you click along. I’ll go super detailed, with screenshots-in-text explanations, common mistakes Indians face (slow internet, low RAM laptops, etc.), and exact steps as of late January 2026.

1. Installing Android Studio (Latest Version in Jan 2026)

As of today (January 27, 2026), the latest stable version is Android Studio Otter 3 Feature Drop (version code 2025.2.3, released mid-January 2026).

  • It’s super AI-powered now — Gemini helps write code, fix bugs, generate Compose UI from descriptions, even suggest fixes for crashes.
  • If you’re adventurous, there’s a Canary preview (Panda 2 | 2025.3.2 Canary 1 from Jan 26), but stick to stable for beginners.

Step-by-step installation (for Windows — most common in India; Mac/Linux similar):

  1. Go to the official site: https://developer.android.com/studio (Use Chrome or Edge; sometimes Firefox blocks downloads on slow connections.)
  2. Click the big green Download Android Studio button. It auto-detects your OS → for Windows it’ll offer android-studio-2025.2.3.9-windows.exe (~1.2–1.5 GB).
    • Pro tip: If your internet is Jio/Airtel flaky, download at night or use a download manager like IDM.
  3. Run the .exe as administrator (right-click → Run as admin — avoids permission issues on Windows 10/11).
  4. Wizard steps:
    • Welcome → Next.
    • Installation Type → Standard (recommended for first-timers — includes Android SDK, Emulator, HAXM/Intel drivers).
    • UI Theme → Light or Dark (Dark is easier on eyes at night).
    • Components → Make sure all are checked: Android SDK, Android SDK Platform-Tools, Android Emulator, Android Virtual Device.
    • Location → Default is fine (C:\Program Files\Android\Android Studio), but if C: is low space, change to D: or E:.
    • Install → It’ll download ~2–4 GB more (SDKs, tools). This can take 30–90 mins on Indian broadband. Pause if needed.
  5. Finish → Launch Android Studio. First launch: It sets up SDK (downloads latest Android 16 SDK ~API 36), Gradle, etc. Another 10–30 mins.

Common India issues & fixes:

  • Slow download? Use VPN (free ones like ProtonVPN) sometimes speeds up Google servers.
  • Low RAM laptop (8GB or less)? Close all tabs/browsers during install. Later, allocate only 1536–2048 MB to emulator.
  • Antivirus blocks? Temporarily disable (McAfee, Quick Heal love to block Android Studio).
  • No space? Clean C: drive first (delete temp files, old Android Studio if upgrading).

After install, you’ll see the Welcome screen — beautiful, with “New Project”, “Open”, etc.

2. Configuring Emulators and Physical Devices

You need a way to test apps — two options: Emulator (virtual phone) or real Android phone.

Option A: Android Emulator (Recommended for beginners — no cable needed)

  1. In Android Studio Welcome → Configure (bottom right) → SDK Manager.
    • SDK Platforms → Check “Android 16.0 (VanillaIceCream)” or latest (API 36).
    • SDK Tools → Check: Android Emulator, Android SDK Platform-Tools, Intel x86 Emulator Accelerator (HAXM installer) if Intel CPU.
    • Apply → Download (~1–2 GB).
  2. Create AVD (Android Virtual Device):
    • Welcome screen → More Actions → Virtual Device Manager → Create Virtual Device.
    • Phone → Pick “Pixel 9” or “Pixel 8 Pro” (modern, has foldable/fold options too).
    • System Image → Download “Android 16 (Google APIs)” if not there → Next.
    • AVD Name: “Pixel_9_API_36” → Finish.
    • Advanced: Enable “Hardware – GLES 2.0” for graphics, set RAM to 2048 MB if your PC has 16GB+.
  3. Launch emulator: In Device Manager → Play button next to your AVD. First boot takes 2–5 mins (subsequent faster). → You now have a virtual Pixel phone on your screen!

Option B: Real Android Phone (Faster, feels real — great for India devs)

  1. On your phone:
    • Settings → About phone → Tap “Build number” 7 times → Developer options enabled.
    • Developer options → Enable “USB debugging”.
    • Also enable “Stay awake” and “Verify apps over USB” if asked.
  2. Connect phone via USB (good cable — cheap ones cause issues).
    • First time: Phone shows “Allow USB debugging?” → Tick “Always allow from this computer” → Allow.
    • In Android Studio: Top-right device dropdown → Your phone appears (e.g., “Redmi Note 13 – API 34”).

Pro tip: If phone not detected → Install drivers (Google USB Driver from SDK Manager) or restart ADB (Terminal: adb kill-server && adb start-server).

3. Creating Your First Project (“Hello World” with Jetpack Compose)

  1. Welcome screen → New Project.
  2. Template → Empty Activity (Compose) — this is modern 2026 way (no old XML).
  3. Configure:
    • Name: HelloWebliance
    • Package name: com.webliance.hellowebliance (use your domain-style)
    • Save location: Default or D:\AndroidProjects
    • Language: Kotlin
    • Minimum SDK: API 24: Android 7.0 (Nougat) — covers ~98% devices in India 2026.
    • Build configuration: Use defaults (AGP 9.0+ now common).
  4. Finish → Android Studio opens your project (may index Gradle — 2–10 mins first time).

Project opens:

  • See MainActivity.kt in src/main/kotlin → This is your code file.

4. Understanding Project Structure (Like Exploring Your New House)

Android projects look scary at first — but it’s organized:

  • app (main module)
    • src/main
      • java/com/webliance/hellowebliance → Kotlin files (MainActivity.kt)
        • MainActivity.kt: Has @Composable fun Greeting() — this is your UI code!
      • res (resources)
        • drawable/ → Images, icons (add your logo here later).
        • layout/ → Old XML (ignore for Compose).
        • mipmap/ → App icons.
        • values/ → strings.xml (app name, texts), colors.xml, themes.
      • AndroidManifest.xml → “ID card” of app: Declares permissions, main Activity, package name.
    • build.gradle.kts (Module: app) → Heart of build: Dependencies (Compose, Material3), compile SDK (36), min SDK. Example snippet:
      Kotlin
    • settings.gradle.kts → Lists modules (usually just :app).
    • build.gradle.kts (Project) → Top-level: Plugins, repositories (Google, Maven).

Gradle = Build system (like “make” for Android) — syncs dependencies, compiles code.

5. Run Your First “Hello World”!

  1. Top toolbar → Device dropdown → Pick emulator or phone.
  2. Click green Run button (▶️) or Shift+F10.
    • First build: 2–5 mins (downloads Gradle, Compose libs).
    • See app install → Launch on emulator/phone.
    • Boom! “Hello Android!” screen (or whatever default text).

Change it: In MainActivity.kt, edit:

Kotlin

Run again → Instant change (hot reload with Compose Live Edit in Otter 3!).

You’ve done it! Your first app lives.

Questions? Stuck on install? Emulator slow? Gemini not showing? Tell me exactly — we’ll fix together. Next chapter: Kotlin basics to make this app interactive. You’re officially an Android dev now — proud of you! Keep going 💪

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *