Skip to content
pubscout

launch_at_startup

0.5.1, released 2 years ago by leanflutter.dev

Allows Flutter desktop apps to automatically launch on startup or login.

$ flutter pub add launch_at_startup
Source repository

What it does

Provides an API to configure, enable, disable, and check the launch-at-startup status for Flutter desktop applications across Windows, macOS, and Linux.

AI-written summary of version 0.5.1, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You are building a Flutter desktop application for Windows, macOS, or Linux.
  • Your app needs the capability to start automatically when the user logs in or boots the system.

Skip it when

  • You are building for mobile or web platforms.
  • You do not want your app running in the background immediately upon user login.

Strengths

  • Supports multiple desktop platforms (Windows, macOS, Linux).
  • Simple API to enable, disable, and check launch status.

Weaknesses

  • Requires manual native setup on macOS (Swift package and build phase configuration).
  • Requires proper app info (such as app name and executable path) to function correctly.

Setup

Kind
Flutter widgets
Effort
Medium
Code generation
No
Direct dependencies
1

Requires initialization code and platform-specific setup on macOS involving Xcode and Swift package dependencies.

void main() async {
  WidgetsFlutterBinding.ensureInitialized();
  PackageInfo packageInfo = await PackageInfo.fromPlatform();
  launchAtStartup.setup(
    appName: packageInfo.appName,
    appPath: Platform.resolvedExecutable,
    packageName: 'dev.leanflutter.examples.launchatstartupexample',
  );
  await launchAtStartup.enable();
  bool isEnabled = await launchAtStartup.isEnabled();
  runApp(const MyApp());
}

Alternatives

Packages that do the same job and could replace launch_at_startup.

Works with

Packages commonly used together with launch_at_startup: ones it builds on, ones built on it, and its own family.