Rana Maninder Singh
Lesson 1 of 8Android App Development

The Android Ecosystem — What You Need to Know Before Writing a Single Line of Code

Lesson opener

In one line: How mobile apps differ from websites - the mental model shift every web developer needs first.

Why it matters: This shows up at work when you need to how mobile apps differ from websites - the mental model shift every web developer needs first.

Before this lesson: py1 / py6

Before you start

ResourceLink
PreviousBA Capstone
NextReact Native fundamentals
PrerequisitesBasic programming ( py1–py6 ) or HTML/CSS/JS with React basics
Time~55 minutes
What you needWindows PC, Android phone (optional but recommended), Wi‑Fi

What you will learn

  • How mobile apps differ from websites — the mental model shift every web developer needs first
  • What Android is and why permissions work differently than a browser
  • Which technology stack this course uses (React Native + Expo) and why
  • The Activity lifecycle — why ignoring it causes one-star reviews
  • Complete Windows setup with exact commands and expected outputs

Section 1 — Web vs mobile: the honest framing

Plain English:

If you build websites, you know:

Mobile apps work completely differently:

This is not harder — it is different. This lesson teaches the difference before teaching the code.


Section 2 — What Android actually is

Plain English:

Android is an operating system built on Linux, maintained by Google, and installed on 3+ billion devices. Your app runs as a sandboxed process on top of this OS.

Unlike a website where the browser handles rendering, security, and network access — your Android app must explicitly request permissions for everything:

CapabilityOn the webOn Android
CameraBrowser may promptYou must declare + request
LocationBrowser may promptYou must declare + request
InternetUsually implicitYou must declare in manifest
StorageSandboxed per originYou must request scoped storage

The OS grants or denies these. The user can revoke them anytime from Settings.

Breaking it down:

Use this when: planning features — if you need GPS, budget time for permission UX and fallback when denied.


Section 3 — Technology choice (decision made for you)

ApproachLanguageProsConsBest for
Native AndroidKotlin/JavaFull device access, best performanceAndroid only, steep curveProfessional Android devs
React NativeJavaScriptWeb-like syntax, cross-platformBridge overhead, some native limitsWeb devs moving to mobile
FlutterDartBeautiful UI, fast, cross-platformNew language (Dart)Fresh starters
PWAHTML/CSS/JSNo install neededLimited device access, no Play StoreSimple use cases

This course uses React Native + Expo because:

  1. You already know JavaScript from web work
  2. One codebase runs on Android and iOS
  3. Expo eliminates most native setup complexity
  4. The mental model transfer from React on the web is fastest

If you want pure native Kotlin — the concepts in this lesson (lifecycle, permissions, store submission) still apply, but the syntax will differ.


Section 4 — The Android app lifecycle

Plain English:

Your app is not always running. The OS can pause it, stop it, or kill it entirely to free memory. Your app must save its state when paused and restore it when resumed.

If you ignore the lifecycle, users will lose data every time they switch to another app and return. This is the #1 source of one-star reviews for new app developers.

StateWhat happenedYour job
ResumedUser is actively using your appRun animations, accept input
PausedAnother app covers yours (dialog, split screen)Stop heavy work; save draft data
StoppedApp not visiblePersist important state
DestroyedOS reclaimed memoryRestore from storage on next launch

With Expo / React Native, much of this is handled by the framework — but your data (game score, form text, high score) still needs explicit persistence. That is why android4 covers AsyncStorage.


Section 5 — Complete setup guide (Windows)

Presented as numbered steps with exact commands and expected outputs.

Step 1 — Install Node.js (required for Expo)

  1. Download: https://nodejs.org → LTS version (20.x or 22.x)
  2. Run the installer → accept defaults → finish
  3. Verify — open Command Prompt (Win+R → cmd):
node --version

Expected: v20.x.x or higher (e.g. v20.18.0)

npm --version

Expected: 10.x.x or higher

Step 2 — Install Expo tooling

Modern Expo uses the CLI via npx (no global install required):

npx expo --version

Expected: version number prints (e.g. 0.22.x or similar — exact number varies)

Optional legacy global install (your docs may reference this): npm install -g expo-cli — not required if you use npx expo everywhere below.

Step 3 — Install Expo Go on your phone

This lets you test on your real device instantly — no emulator required for lesson one.

Step 4 — Create your first project

npx create-expo-app MyFirstApp
cd MyFirstApp
npx expo start

Expected terminal output: Metro bundler starts, QR code appears in terminal or browser DevTools.

Step 5 — Connect your phone

  1. Ensure phone and computer are on the same Wi‑Fi
  2. Open Expo Go on your phone
  3. Scan the QR code from the terminal (Android: scan from Expo Go; iOS: Camera app)
  4. Your app appears on your phone — default Expo welcome screen

Common setup failures:**

- Firewall blocking port 19000 → temporarily allow Node/Expo through Windows Firewall, or run npx expo start --tunnel (slower but works across networks)

- Different Wi‑Fi networks → connect phone to the same network as your laptop

- Expo Go version mismatch → update Expo Go from the Play Store / App Store

- Corporate VPN → disconnect VPN on both devices for local testing


Practice

Do this now:

  1. Run node --version and npx expo --version — screenshot or note the output
  2. Create MyFirstApp and load it in Expo Go on your phone
  3. Switch to another app and back — notice the app may reload (development mode); note why persistence matters for android4

Checklist

Before moving to React Native fundamentals, confirm:

  • [ ] Can you explain three ways mobile apps differ from websites?
  • [ ] Do you know why Android requires explicit permissions?
  • [ ] Can you name the lifecycle states where you should save user data?
  • [ ] Did npx create-expo-app and npx expo start work on your machine?
  • [ ] Did the app load on your phone via Expo Go?

What's next

React Native fundamentals for web developers — every HTML/CSS concept mapped to mobile components.

Same codebase on iOS: After android8, continue with iOS App Development on a Mac — React Native shares most of your game code; Apple’s store rules and design guidelines differ.