Installing Visual Studio

Windows

1. Install Flutter SDK

l Go to the official download page: Flutter SDK for Windows.

l Download the .zip file (not the installer).

l Extract it to a folder (e.g. C:\src\flutter).

l Add Flutter to PATH:

  • Search for Environment Variables in Windows.

  • Edit Path → Add:

  • - C:\src\flutter\bin

2. Check Installation

l Open Command Prompt or PowerShell and run:

- flutter doctor

It will check for:

  • Flutter SDK

  • Android Studio (for mobile dev)

  • Visual Studio (needed for Windows apps)

  • Connected devices

- If you only want Windows apps, you mainly need Visual Studio (not VS Code).

3. Install Visual Studio (Community Edition)

l Download: Visual Studio Community.

l During install, select:

  • Desktop development with C++

  • Universal Windows Platform (UWP) development

l These provide the necessary compilers & libraries.

4. Enable Windows Desktop Support

l Check if desktop support is enabled:

- flutter doctor

l If not enabled, run:

- flutter config --enable-windows-desktop

5. Create or Open a Flutter Project

l To create a new project:

  • flutter create my_app

  • cd my_app

l To enable Windows as a target, ensure the project has a windows/ folder.

If missing, run:

- flutter create .

6. Run Flutter App on Windows

l Run inside your project folder:

`- flutter run -d windows

  • -d windows means run on Windows desktop.

  • It will open a .exe app in a new window.

7. Build a Windows Executable (.exe)

l To generate a distributable .exe:

- flutter build windows

l You’ll find the .exe here:

- build\windows\x64\runner\Release\my_app.exe

Mac

1. System Requirements

l OS: macOS 10.14 (Mojave) or later.

l Xcode installed (needed for macOS desktop apps).

l Homebrew (recommended for easy installs).

2. Install Flutter SDK

  • Download the Flutter SDK for macOS:

    • Flutter SDK for macOS

      • Choose the .zip version.

  • Extract it to a folder, e.g.: ~/development/flutter

  • Add Flutter to PATH (so terminal can find it):

    • Edit your shell profile (~/.zshrc or ~/.bashrc):

export PATH="$PATH:$HOME/development/flutter/bin"

  • Reload terminal: source ~/.zshrc

2. Check Setup

l Run:

  • Flutter doctor

l This checks:

  • Flutter SDK

  • Xcode

  • macOS desktop support

  • Connected devices

l Make sure "macOS desktop" shows as available.

4. Enable macOS Desktop Support

l If not enabled:

- flutter config --enable-macos-desktop

5. Install Xcode (for building macOS apps)

l Download from App Store or Apple Developer site.

l Open Xcode once → accept license → install command-line tools:

- sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer

- sudo xcodebuild -runFirstLaunch

6. Create or Open a Flutter Project

l To create a new project:

- flutter create my_app

- cd my_app

l If your project doesn’t have a macos/ folder, add it:

- flutter create .

7. Run on macOS Desktop

l Run inside project:

- flutter run -d macos

l This launches your Flutter app as a native macOS desktop app.

8. Build macOS App (Distributable)

l To create a macOS .app bundle:

- flutter build macos

l The output will be in:

- build/macos/Build/Products/Release/my_app.app

You can double-click my_app.app to run, or zip/share it.

Last updated