To run your Flutter app on a real device, you can follow these steps:
- Connect your device to your computer using a USB cable.
- Make sure that your device is recognized by your computer. You can do this by running the command
adb devicesin the terminal or command prompt. This should show a list of connected devices, including your device.
- In the terminal or command prompt, navigate to the root directory of your Flutter project.
- Run the following command to install your app on your device:
- Wait for the app to build and install on your device. You should see output in the terminal or command prompt indicating the progress of the build and installation process.
- Once the app is installed, it should launch automatically on your device. You can also find it in the app drawer on your device.
Note: Before you can run your app on an Android device, you may need to enable USB debugging on your device. On an iOS device, you may need to trust your computer on the device before you can run your app.