---
description: Learn how to overwrite your native Android and iOS project configurations before building in Capawesome Cloud.
title: Overwrite Native Configurations - Capawesome
image: https://capawesome.io/docs/assets/images/social/cloud/native-builds/guides/native-configurations.png
---

[ Skip to content](#overwrite-native-configurations) 

[ 🎉 Introducing **Capawesome Platform** — one platform for Live Updates, Native Builds, App Store Publishing, and Insider SDKs.](https://capawesome.io) 

* [  Formbricks ](/docs/plugins/formbricks/)
* [  Geocoder ](/docs/plugins/geocoder/)
* [  Google Sign-In ](/docs/plugins/google-sign-in/)
* [  Grafana Faro ](/docs/plugins/grafana-faro/)
* [  libSQL ](/docs/plugins/libsql/)
* [  Live Update ](/docs/plugins/live-update/)
* [  Managed Configurations ](/docs/plugins/managed-configurations/)
* [  Media Session ](/docs/plugins/media-session/)
* [  ML Kit ](/docs/plugins/mlkit/)
* [  Navigation Bar ](/docs/plugins/navigation-bar/)
* [  NFC ](/docs/plugins/nfc/)
* [  OAuth ](/docs/plugins/oauth/)
* [  Pedometer ](/docs/plugins/pedometer/)
* [  Photo Editor ](/docs/plugins/photo-editor/)
* [  PostHog ](/docs/plugins/posthog/)
* [  Printer ](/docs/plugins/printer/)
* [  Purchases ](/docs/plugins/purchases/)
* [  RealtimeKit ](/docs/plugins/realtimekit/)
* [  Screen Orientation ](/docs/plugins/screen-orientation/)
* [  Screenshot ](/docs/plugins/screenshot/)
* [  Secure Preferences ](/docs/plugins/secure-preferences/)
* [  Speech Recognition ](/docs/plugins/speech-recognition/)
* [  Speech Synthesis ](/docs/plugins/speech-synthesis/)
* [  Share Target ](/docs/plugins/share-target/)
* [  Square Mobile Payments ](/docs/plugins/square-mobile-payments/)
* [  SQLite ](/docs/plugins/sqlite/)
* [  Superwall ](/docs/plugins/superwall/)
* [  Torch ](/docs/plugins/torch/)
* [  Wifi ](/docs/plugins/wifi/)
* [  Zip ](/docs/plugins/zip/)
* [  Cloud ](/docs/cloud/)
* [  Live Updates ](/docs/cloud/live-updates/)
* Advanced
* Integrations
* [  Native Builds ](/docs/cloud/native-builds/)
* [  Configuration ](/docs/cloud/native-builds/configuration/)
* [  Environments ](/docs/cloud/native-builds/environments/)
* Guides
* [  Auto-Increment Build Numbers ](/docs/cloud/native-builds/guides/auto-incrementing-build-numbers/)
* [  Override Java Version ](/docs/cloud/native-builds/guides/override-java-version/)
* [  Custom iOS Provisioning Profiles ](/docs/cloud/native-builds/guides/custom-ios-provisioning-profiles/)
* [  Install APK on Android Device ](/docs/cloud/native-builds/guides/install-apk-on-android-device/)
* [  Install IPA on iOS Device ](/docs/cloud/native-builds/guides/install-ipa-on-ios-device/)
* [  Sample Projects ](/docs/cloud/native-builds/sample-projects/)
* [  Troubleshooting ](/docs/cloud/native-builds/troubleshooting/)
* [  Automations ](/docs/cloud/automations/)
* [  Assist ](/docs/cloud/assist/)
* Account
* Organizations
* [  Organization and User Management ](/docs/cloud/organizations/memberships/)
* [  Single Sign-On (SSO) ](/docs/cloud/organizations/sso/)
* [  Teams ](/docs/cloud/organizations/teams/)
* [  Two-Factor Authentication ](/docs/cloud/organizations/two-factor-authentication/)
* [  Integrations ](/docs/cloud/integrations/)
* [  License Keys ](/docs/cloud/license-keys/)
* [  Webhooks ](/docs/cloud/webhooks/)
* [  Pricing ](https://capawesome.io/pricing/)
* [  FAQ ](/docs/cloud/faq/)
* [  Support ](/docs/cloud/support/)
* [  Contributing ](/docs/contributing/)
* [  LLMs ](/docs/llms/)
* [  Insiders ](/docs/insiders/)
* [  License ](https://capawesome.io/legal/eula/)
* [  Support ](/docs/insiders/support/)
* [  FAQ ](/docs/insiders/faq/)
* [  Blog ](/blog/)
* Categories

# Overwrite Native Configurations[¶](#overwrite-native-configurations "Permanent link")

You can automatically overwrite your native Android and iOS project configurations before building in [Capawesome Cloud](/). This is useful for modifying app identifiers, display names, version numbers, and other native configurations based on your build environment or branch.

This guide shows you how to use [Trapeze](https://trapeze.dev/), a mobile app configuration tool, to automate native project modifications during the build process.

## Installation[¶](#installation "Permanent link")

First, install Trapeze as a development dependency in your project:

`[](#%5F%5Fcodelineno-0-1)npm install --save-dev @trapezedev/configure
`

## Configuration File[¶](#configuration-file "Permanent link")

Create a configuration file named `capawesome.yml` in the root of your project. This file defines the native configurations you want to overwrite.

Here's a basic example that modifies the App ID and display name:

`[](#%5F%5Fcodelineno-1-1)platforms:
[](#%5F%5Fcodelineno-1-2)  android:
[](#%5F%5Fcodelineno-1-3)    packageName: com.example.myapp
[](#%5F%5Fcodelineno-1-4)    appName: My App
[](#%5F%5Fcodelineno-1-5)  ios:
[](#%5F%5Fcodelineno-1-6)    bundleId: com.example.myapp
[](#%5F%5Fcodelineno-1-7)    displayName: My App
`

Platform-specific configurations 

Trapeze uses platform-specific keys for similar configurations. For example, Android uses `packageName` while iOS uses `bundleId`. Refer to the [Android](https://trapeze.dev/docs/Operations/android) and [iOS](https://trapeze.dev/docs/Operations/ios) operation guides for complete lists of available configurations.

## Build Script[¶](#build-script "Permanent link")

Add an npm script to your `package.json` that runs Trapeze for Android and iOS platforms before the web build process:

`[](#%5F%5Fcodelineno-2-1){
[](#%5F%5Fcodelineno-2-2)  "scripts": {
[](#%5F%5Fcodelineno-2-3)    "capawesome:build": "if [ \"$CI_PLATFORM\" = \"ios\" ] || [ \"$CI_PLATFORM\" = \"android\" ]; then npx trapeze run capawesome.yml -y --$CI_PLATFORM; fi && npm run build"
[](#%5F%5Fcodelineno-2-4)  }
[](#%5F%5Fcodelineno-2-5)}
`

Capawesome Cloud automatically calls the [web build script](/docs/cloud/native-builds/guides/web-build-script/) during the build process. The script conditionally runs Trapeze only for iOS and Android platforms using the `$CI_PLATFORM` environment variable.

## Using Environment Variables[¶](#using-environment-variables "Permanent link")

You can use Capawesome Cloud's [environment variables](/docs/cloud/native-builds/environments/) to dynamically configure your native projects. This is particularly useful for overwriting configurations based on your build environment.

### Define Variables[¶](#define-variables "Permanent link")

First, define variables in your configuration file:

`[](#%5F%5Fcodelineno-3-1)vars:
[](#%5F%5Fcodelineno-3-2)  APP_ID:
[](#%5F%5Fcodelineno-3-3)  APP_NAME:
[](#%5F%5Fcodelineno-3-4)
[](#%5F%5Fcodelineno-3-5)platforms:
[](#%5F%5Fcodelineno-3-6)  android:
[](#%5F%5Fcodelineno-3-7)    packageName: $APP_ID
[](#%5F%5Fcodelineno-3-8)    appName: $APP_NAME
[](#%5F%5Fcodelineno-3-9)  ios:
[](#%5F%5Fcodelineno-3-10)    bundleId: $APP_ID
[](#%5F%5Fcodelineno-3-11)    displayName: $APP_NAME
`

### Set Variable Values[¶](#set-variable-values "Permanent link")

Then, set the variable values in your Capawesome Cloud environment:

1. Navigate to the [Environments](https://console.cloud.capawesome.io/apps/%5F/environments) page
2. Select your environment or create a new one
3. Add variables with their values:
4. `APP_ID`: `com.example.myapp`
5. `APP_NAME`: `My App`

You can create multiple environments with different values (e.g., development, staging, production) and select the appropriate environment when triggering a build.

Default values 

You can provide default values for variables that will be used if no environment variable is set:

`[](#%5F%5Fcodelineno-4-1)vars:
[](#%5F%5Fcodelineno-4-2)  APP_ID:
[](#%5F%5Fcodelineno-4-3)    default: com.example.default
[](#%5F%5Fcodelineno-4-4)  APP_NAME:
[](#%5F%5Fcodelineno-4-5)    default: Default App Name
`

May 7, 2026 

 Back to top 