|
| 1 | +--- |
| 2 | +slug: /deployment/google-playstore-deployment |
| 3 | +title: Google Play Store Deployment |
| 4 | +description: Learn how to deploy your apps to the Google Play Store using Dreamflow. |
| 5 | +tags: [Google Play Store, Deployment, Dreamflow, Android] |
| 6 | +sidebar_position: 3 |
| 7 | +toc_max_heading_level: 4 |
| 8 | +keywords: [Google Play Store, Deployment, Dreamflow, Android] |
| 9 | +--- |
| 10 | + |
| 11 | +# Google Play Store Deployment |
| 12 | + |
| 13 | +Dreamflow allows you to deploy your apps directly to the Google Play Store from within the platform. This guide covers all the necessary prerequisites, a step-by-step deployment process, and common troubleshooting tips. |
| 14 | + |
| 15 | +:::info[Prerequisites] |
| 16 | + |
| 17 | +- Register for a [**Google Play Developer account**](https://play.google.com/console/signup). |
| 18 | +- Ensure you have set an app launcher icon. If not, add an app icon to the Dreamflow assets, then use the [**flutter_launcher_icons**](https://pub.dev/packages/flutter_launcher_icons) package or ask the AI agent to set it up for you. |
| 19 | +- Ensure your app package name is correct, as it cannot be changed after deployment. To verify it, open `android/app/build.gradle` and check the `applicationId`. To update the package name, you can use the [**change_app_package_name**](https://pub.dev/packages/change_app_package_name) package or simply ask the AI agent. |
| 20 | +- It's recommended to [**test your app on a real device**](../test/test-on-mobile-device.md) before deployment. |
| 21 | + |
| 22 | +::: |
| 23 | + |
| 24 | +## 1. Creating app on Google Play Store |
| 25 | + |
| 26 | +To create a new app in the Google Play Store, start by opening the [Google Play Console](https://play.google.com/console) and clicking the **Create app** button. Enter the **App name**, select the app type, and choose whether the app will be **Free** or **Paid**. After that, accept the **Declarations**, and finally click **Create app** to proceed. |
| 27 | + |
| 28 | +<div style={{ |
| 29 | + position: 'relative', |
| 30 | + paddingBottom: 'calc(50.67989417989418% + 41px)', // Keeps the aspect ratio and additional padding |
| 31 | + height: 0, |
| 32 | + width: '100%'}}> |
| 33 | + <iframe |
| 34 | + src="https://demo.arcade.software/364L2UfaOKcHiJH5GIAv?embed&show_copy_link=true" |
| 35 | + title="" |
| 36 | + style={{ |
| 37 | + position: 'absolute', |
| 38 | + top: 0, |
| 39 | + left: 0, |
| 40 | + width: '100%', |
| 41 | + height: '100%', |
| 42 | + colorScheme: 'light' |
| 43 | + }} |
| 44 | + frameborder="0" |
| 45 | + loading="lazy" |
| 46 | + webkitAllowFullScreen |
| 47 | + mozAllowFullScreen |
| 48 | + allowFullScreen |
| 49 | + allow="clipboard-write"> |
| 50 | + </iframe> |
| 51 | +</div> |
| 52 | +<p></p> |
| 53 | + |
| 54 | +## 2. Set up your app |
| 55 | + |
| 56 | +To provide the app details required by the Google Play Store, go to the **Set up your app** section within your newly created app. Expand the **View tasks** list, then click on each task and complete the required information step by step. |
| 57 | + |
| 58 | + |
| 59 | + |
| 60 | +## 3. Adding service account credentials |
| 61 | + |
| 62 | +To enable Dreamflow to deploy your app to the Google Play Store, you need to add service account credentials. |
| 63 | + |
| 64 | +### 3.1 Creating a Service Account |
| 65 | + |
| 66 | +To create the Service Account, you can follow the instructions from [here](https://developers.google.com/android-publisher/getting_started). To help you get started quickly, here are the exact steps you need to follow: |
| 67 | + |
| 68 | +1. If you haven't set up Firebase in your app, you'll need to [create a Google Cloud Project](https://developers.google.com/android-publisher/getting_started#creating). |
| 69 | +2. Then, head over to the [Google Play Developer API page](https://console.developers.google.com/apis/api/androidpublisher.googleapis.com/) in Google Cloud Console and click **Enable**. |
| 70 | + |
| 71 | +  |
| 72 | + |
| 73 | +3. In Google Cloud Console, go to [Service Accounts](https://console.cloud.google.com/iam-admin/serviceaccounts), click + **CREATE SERVICE ACCOUNT,** and follow the steps as shown below. |
| 74 | + |
| 75 | + <div style={{ |
| 76 | + position: 'relative', |
| 77 | + paddingBottom: 'calc(50.67989417989418% + 41px)', // Keeps the aspect ratio and additional padding |
| 78 | + height: 0, |
| 79 | + width: '100%'}}> |
| 80 | + <iframe |
| 81 | + src="https://demo.arcade.software/v4qg6mfKvbKGKISqJZg8?embed&show_copy_link=true" |
| 82 | + title="" |
| 83 | + style={{ |
| 84 | + position: 'absolute', |
| 85 | + top: 0, |
| 86 | + left: 0, |
| 87 | + width: '100%', |
| 88 | + height: '100%', |
| 89 | + colorScheme: 'light' |
| 90 | + }} |
| 91 | + frameborder="0" |
| 92 | + loading="lazy" |
| 93 | + webkitAllowFullScreen |
| 94 | + mozAllowFullScreen |
| 95 | + allowFullScreen |
| 96 | + allow="clipboard-write"> |
| 97 | + </iframe> |
| 98 | + </div> |
| 99 | + <p></p> |
| 100 | + |
| 101 | + |
| 102 | +4. Now, download the JSON key file by clicking **ADD Key > Create new key > select JSON > CREATE**. Keep this file secure. |
| 103 | + |
| 104 | + <div style={{ |
| 105 | + position: 'relative', |
| 106 | + paddingBottom: 'calc(50.67989417989418% + 41px)', // Keeps the aspect ratio and additional padding |
| 107 | + height: 0, |
| 108 | + width: '100%'}}> |
| 109 | + <iframe |
| 110 | + src="https://demo.arcade.software/ZMZFspS0ZI3xIc0bSago?embed&show_copy_link=true" |
| 111 | + title="" |
| 112 | + style={{ |
| 113 | + position: 'absolute', |
| 114 | + top: 0, |
| 115 | + left: 0, |
| 116 | + width: '100%', |
| 117 | + height: '100%', |
| 118 | + colorScheme: 'light' |
| 119 | + }} |
| 120 | + frameborder="0" |
| 121 | + loading="lazy" |
| 122 | + webkitAllowFullScreen |
| 123 | + mozAllowFullScreen |
| 124 | + allowFullScreen |
| 125 | + allow="clipboard-write"> |
| 126 | + </iframe> |
| 127 | + </div> |
| 128 | + <p></p> |
| 129 | + |
| 130 | +5. In **Google Play Console**, go to [Users & Permissions](https://play.google.com/console), click **Invite new users**, and add your service account email with these permissions: |
| 131 | + - "Edit and delete draft apps" |
| 132 | + - "Release to production..." |
| 133 | + - "Release apps to testing tracks" |
| 134 | + - "Manage testing tracks and edit tester lists" |
| 135 | + |
| 136 | + <p></p> |
| 137 | + |
| 138 | + <div style={{ |
| 139 | + position: 'relative', |
| 140 | + paddingBottom: 'calc(50.67989417989418% + 41px)', // Keeps the aspect ratio and additional padding |
| 141 | + height: 0, |
| 142 | + width: '100%'}}> |
| 143 | + <iframe |
| 144 | + src="https://demo.arcade.software/PLVogskcfVTMqJk4nfig?embed&show_copy_link=true" |
| 145 | + title="" |
| 146 | + style={{ |
| 147 | + position: 'absolute', |
| 148 | + top: 0, |
| 149 | + left: 0, |
| 150 | + width: '100%', |
| 151 | + height: '100%', |
| 152 | + colorScheme: 'light' |
| 153 | + }} |
| 154 | + frameborder="0" |
| 155 | + loading="lazy" |
| 156 | + webkitAllowFullScreen |
| 157 | + mozAllowFullScreen |
| 158 | + allowFullScreen |
| 159 | + allow="clipboard-write"> |
| 160 | + </iframe> |
| 161 | + </div> |
| 162 | + <p></p> |
| 163 | + |
| 164 | +### 3.2 Uploading service account credentials to Dreamflow |
| 165 | + |
| 166 | +To upload your service account credentials in Dreamflow, go to **Publish > Android**. Under **Google Play Credentials**, click **Upload .json** and select the `.json` file you downloaded in step 4. |
| 167 | + |
| 168 | + |
| 169 | + |
| 170 | +## 4. Deploy to Google Play Store |
| 171 | + |
| 172 | +For first-time deployment, you need to create an initial release manually in Google Play Console. After that, Dreamflow can handle all subsequent deployments. |
| 173 | + |
| 174 | +### 4.1 Downloading AAB file |
| 175 | + |
| 176 | +In DreamFlow, set the **Google Play Track** to **Internal**, enter the **Bundle ID** and **Version Code**, then click **Submit Build to Google Play**. Wait a few minutes and click **Check Deployment Status**. |
| 177 | + |
| 178 | +Once the build is complete, click **Download AAB File** button (in the **App Bundle** section). If the button is still disabled, wait a bit longer and try again. |
| 179 | + |
| 180 | +:::info |
| 181 | + |
| 182 | +Even if the build status appears as FAILURE, you can still download the AAB file. |
| 183 | + |
| 184 | +::: |
| 185 | + |
| 186 | +<div style={{ |
| 187 | + position: 'relative', |
| 188 | + paddingBottom: 'calc(50.67989417989418% + 41px)', // Keeps the aspect ratio and additional padding |
| 189 | + height: 0, |
| 190 | + width: '100%'}}> |
| 191 | + <iframe |
| 192 | + src="https://demo.arcade.software/pBlnRQnHLQRjSFWJTtHw?embed&show_copy_link=true" |
| 193 | + title="" |
| 194 | + style={{ |
| 195 | + position: 'absolute', |
| 196 | + top: 0, |
| 197 | + left: 0, |
| 198 | + width: '100%', |
| 199 | + height: '100%', |
| 200 | + colorScheme: 'light' |
| 201 | + }} |
| 202 | + frameborder="0" |
| 203 | + loading="lazy" |
| 204 | + webkitAllowFullScreen |
| 205 | + mozAllowFullScreen |
| 206 | + allowFullScreen |
| 207 | + allow="clipboard-write"> |
| 208 | + </iframe> |
| 209 | +</div> |
| 210 | +<p></p> |
| 211 | + |
| 212 | +### 4.2 Upload AAB file to Internal testing track |
| 213 | + |
| 214 | +In Google Play Console, create an **Internal Testing** track and upload the **.aab** file. |
| 215 | + |
| 216 | +<div style={{ |
| 217 | + position: 'relative', |
| 218 | + paddingBottom: 'calc(50.67989417989418% + 41px)', // Keeps the aspect ratio and additional padding |
| 219 | + height: 0, |
| 220 | + width: '100%'}}> |
| 221 | + <iframe |
| 222 | + src="https://demo.arcade.software/PJt1oXAVn7Wpvjb6zYCb?embed&show_copy_link=true" |
| 223 | + title="" |
| 224 | + style={{ |
| 225 | + position: 'absolute', |
| 226 | + top: 0, |
| 227 | + left: 0, |
| 228 | + width: '100%', |
| 229 | + height: '100%', |
| 230 | + colorScheme: 'light' |
| 231 | + }} |
| 232 | + frameborder="0" |
| 233 | + loading="lazy" |
| 234 | + webkitAllowFullScreen |
| 235 | + mozAllowFullScreen |
| 236 | + allowFullScreen |
| 237 | + allow="clipboard-write"> |
| 238 | + </iframe> |
| 239 | +</div> |
| 240 | +<p></p> |
| 241 | + |
| 242 | +:::info |
| 243 | +After the internal testing track is set up, DreamFlow can handle all future deployments directly. |
| 244 | +::: |
| 245 | + |
| 246 | +### 4.3 Deploy from Dreamflow |
| 247 | + |
| 248 | +To deploy your app from Dreamflow, navigate to **Publish > Android**, set the **Track** to Internal, and update the **version code.** If your app is still in draft mode (not yet available on the Play Store), set **Submit as Draft** (under **Deployment Flags)** to **True**, and then click **Deploy to Play Store**. |
| 249 | + |
| 250 | +<div style={{ |
| 251 | + position: 'relative', |
| 252 | + paddingBottom: 'calc(50.67989417989418% + 41px)', // Keeps the aspect ratio and additional padding |
| 253 | + height: 0, |
| 254 | + width: '100%'}}> |
| 255 | + <iframe |
| 256 | + src="https://demo.arcade.software/lryE56z4DG52mIeJLwhn?embed&show_copy_link=true" |
| 257 | + title="" |
| 258 | + style={{ |
| 259 | + position: 'absolute', |
| 260 | + top: 0, |
| 261 | + left: 0, |
| 262 | + width: '100%', |
| 263 | + height: '100%', |
| 264 | + colorScheme: 'light' |
| 265 | + }} |
| 266 | + frameborder="0" |
| 267 | + loading="lazy" |
| 268 | + webkitAllowFullScreen |
| 269 | + mozAllowFullScreen |
| 270 | + allowFullScreen |
| 271 | + allow="clipboard-write"> |
| 272 | + </iframe> |
| 273 | +</div> |
| 274 | +<p></p> |
| 275 | + |
| 276 | +:::info |
| 277 | + |
| 278 | +- If another deployment is already in progress, deploying a new build will cancel the previous one. |
| 279 | +- It may take a few minutes for the request to process. Once completed, you will get a pop-up saying *Your app is being deployed to Google Play.* |
| 280 | + |
| 281 | +::: |
| 282 | + |
| 283 | +### 4.4 Verify deployment |
| 284 | + |
| 285 | +To verify that the app is deployed to Play Console: |
| 286 | + |
| 287 | +1. Open the **Internal testing** in [Google Play Console](https://play.google.com/console). |
| 288 | +2. Under the **Releases** section, find your release and click on the **Show Summary** button. |
| 289 | +3. See the **Version Codes** number is increased. |
| 290 | + |
| 291 | + |
| 292 | + |
| 293 | +### 4.5 Deploy to production |
| 294 | + |
| 295 | +To promote your app to production, open your **Internal testing** track in Google Play Console and complete the release. Once the internal release is finalized, click **Promote Release > Production**. |
| 296 | + |
| 297 | +<div style={{ |
| 298 | + position: 'relative', |
| 299 | + paddingBottom: 'calc(50.67989417989418% + 41px)', // Keeps the aspect ratio and additional padding |
| 300 | + height: 0, |
| 301 | + width: '100%'}}> |
| 302 | + <iframe |
| 303 | + src="https://demo.arcade.software/8TQoQjPZEetKsEptLJ2w?embed&show_copy_link=true" |
| 304 | + title="" |
| 305 | + style={{ |
| 306 | + position: 'absolute', |
| 307 | + top: 0, |
| 308 | + left: 0, |
| 309 | + width: '100%', |
| 310 | + height: '100%', |
| 311 | + colorScheme: 'light' |
| 312 | + }} |
| 313 | + frameborder="0" |
| 314 | + loading="lazy" |
| 315 | + webkitAllowFullScreen |
| 316 | + mozAllowFullScreen |
| 317 | + allowFullScreen |
| 318 | + allow="clipboard-write"> |
| 319 | + </iframe> |
| 320 | +</div> |
| 321 | +<p></p> |
| 322 | + |
| 323 | +For all future deployments, set the **Google Play Track** to **Prod** in Dreamflow and deploy directly from there. |
| 324 | + |
| 325 | + |
| 326 | + |
| 327 | +## Deployment Flags |
| 328 | + |
| 329 | +### Submit as draft |
| 330 | + |
| 331 | +While deploying, if your app is still in draft mode, meaning it is not available on the Play Store yet, you may encounter an error message stating, 'Only releases with the status draft may be created on a draft app.' |
| 332 | + |
| 333 | +To resolve this, enable this option, and you'll see that the release will be created as a draft. You'll then need to manually roll out the app. |
| 334 | + |
| 335 | +### Changes not sent for review |
| 336 | + |
| 337 | +If you face an error that says '*Changes cannot be sent for review automatically*', enable this option and retry deployment. |
| 338 | + |
| 339 | +## FAQs |
| 340 | + |
| 341 | +<details> |
| 342 | +<summary> |
| 343 | +Why am I getting an "Invalid Package Name" error? |
| 344 | +</summary> |
| 345 | +<p> |
| 346 | +This happens when your package name already exists or doesn’t meet validation requirements. Make sure your package name is unique and not already used by another app on Google Play Store. Note that the package name cannot be changed after deployment. |
| 347 | +</p> |
| 348 | +</details> |
| 349 | + |
| 350 | +<details> |
| 351 | +<summary> |
| 352 | +What should I do if I see "The service account does not have permission to perform this action"? |
| 353 | +</summary> |
| 354 | +<p> |
| 355 | +This means your service account doesn’t have the correct permissions. In Google Play Console, ensure the account has these permissions: |
| 356 | + |
| 357 | +- *Edit and delete draft apps* |
| 358 | +- *Release to production...* |
| 359 | +- *Release apps to testing tracks* |
| 360 | +- *Manage testing tracks and edit tester lists* |
| 361 | +</p> |
| 362 | +</details> |
| 363 | + |
| 364 | + |
| 365 | + |
| 366 | + |
| 367 | + |
| 368 | +<details> |
| 369 | +<summary> |
| 370 | +Why does my first upload fail with a message like "You need to use a different package name"? |
| 371 | + |
| 372 | +</summary> |
| 373 | +<p> |
| 374 | +For the initial deployment, you must manually [**download the .aab file**](#41-downloading-aab-file) and [**upload it to internal testing track**](#42-upload-aab-file-to-internal-testing-track) in Google Play Console. Once the initial track is set up, Dreamflow will handle all subsequent deployments automatically. |
| 375 | +</p> |
| 376 | +</details> |
| 377 | + |
| 378 | + |
0 commit comments