config/nativephp.php file. This page documents all available configuration options.
Publishing Configuration
The configuration file is published during installation, but you can republish it anytime:App Settings
Version
The human-readable version of your app (e.g., “1.0.0”, “2.1.3”). This is used as the
versionName in Android builds and may be displayed in the app or console.Environment Variable: NATIVEPHP_APP_VERSIONVersion Code
The internal numeric version code used for Play Store builds. This must increase with every release. Used as
versionCode in Android builds and required for publishing updates.Environment Variable: NATIVEPHP_APP_VERSION_CODEApp ID
The unique identifier for your application. Written in reverse domain format (e.g.,
com.nativephp.app). This is used by both Android and iOS to uniquely identify your app.Environment Variable: NATIVEPHP_APP_IDDeep Linking
Custom URL scheme for opening your app (e.g.,
myapp://some/path). This allows other apps and websites to deep link into your app.Environment Variable: NATIVEPHP_DEEPLINK_SCHEMEDomain name for verified HTTPS links and NFC tags (e.g.,
example.com). This allows URLs like https://example.com/path to open your app when tapped from NFC tags or browsers.Environment Variable: NATIVEPHP_DEEPLINK_HOSTStart URL
The initial path to load when the app starts. Should be a path relative to your app root (e.g.,
/dashboard, /onboarding).Environment Variable: NATIVEPHP_START_URLiOS Settings
Development Team
Your Apple Developer Team ID for code signing iOS apps. This is automatically detected from your installed certificates, but can be overridden here. Find your Team ID in your Apple Developer account under Membership details.Environment Variable:
NATIVEPHP_DEVELOPMENT_TEAMiPad Support
Enable or disable iPad support for your iOS app. When enabled, your app will support iPad devices and all iPad orientations as required by Apple’s App Store guidelines. When disabled, your app will be iPhone-only.
Android Settings
Path to the JDK installation to use for Gradle builds.Environment Variable:
NATIVEPHP_GRADLE_PATHPath to your Android SDK installation.Environment Variable:
NATIVEPHP_ANDROID_SDK_LOCATIONPath to the Android emulator binary.Environment Variable:
ANDROID_EMULATORPath to 7-Zip executable (Windows only).Environment Variable:
NATIVEPHP_7ZIP_LOCATIONStatus Bar Style
Controls the color of status bar and navigation bar icons.Options:
auto- Auto-detect from system theme (recommended)light- Light/white iconsdark- Dark icons
NATIVEPHP_ANDROID_STATUS_BAR_STYLEBuild Configuration
Android build optimization settings:Enable R8/ProGuard minification to reduce APK size.Environment Variable:
NATIVEPHP_ANDROID_MINIFY_ENABLEDRemove unused resources from the APK.Environment Variable:
NATIVEPHP_ANDROID_SHRINK_RESOURCESObfuscate code to make reverse engineering harder.Environment Variable:
NATIVEPHP_ANDROID_OBFUSCATEDebug symbol configuration. Options:
FULL, LINE_TABLES_ONLY, NONE.Environment Variable: NATIVEPHP_ANDROID_DEBUG_SYMBOLSGenerate ProGuard mapping files for crash report deobfuscation.Environment Variable:
NATIVEPHP_ANDROID_MAPPING_FILESEnable parallel Gradle builds for faster compilation.Environment Variable:
NATIVEPHP_ANDROID_PARALLEL_BUILDSEnable incremental builds to speed up subsequent builds.Environment Variable:
NATIVEPHP_ANDROID_INCREMENTAL_BUILDSDevice Orientation
Configure which orientations your app supports on different devices:iPhone Orientation
Support portrait mode (home button at bottom)
Support upside-down portrait (home button at top)
Support landscape with home button on left
Support landscape with home button on right
Android Orientation
For iPad, all orientations are automatically supported when
ipad is enabled, as required by Apple’s guidelines.Security
Environment Key Cleanup
Environment variable keys to remove from
.env during app bundling. This prevents secrets or development credentials from being leaked in the bundled app. Wildcards are supported.File Exclusion
Files and folders to remove before the final bundle is built. Use glob/wildcard patterns to skip unnecessary assets like logs, sessions, or temp data.
Development Server
Configuration for the NativePHP development server that enables hot reloading:HTTP server port for serving the app.Environment Variable:
NATIVEPHP_HTTP_PORTWebSocket server port for hot reload communication.Environment Variable:
NATIVEPHP_WS_PORTService name advertised on the network via mDNS.Environment Variable:
NATIVEPHP_SERVICE_NAMEService type for mDNS advertisement.
Public directory to serve (relative to Laravel root).Environment Variable:
NATIVEPHP_PUBLIC_PATHBuild output directory where the ZIP will be created.Environment Variable:
NATIVEPHP_BUILD_PATHAutomatically open browser with QR code when server starts.Environment Variable:
NATIVEPHP_OPEN_BROWSERDirectories to watch for changes during development.
File extensions to watch for changes.
Hot Reload
Configuration for hot reload functionality:Directories to monitor for file changes.
Regex patterns for paths to exclude from watching.
App Store Connect
Configuration for uploading apps to App Store Connect:App Store Connect API key (store in
.env).Environment Variable: APP_STORE_API_KEYApp Store Connect API Key ID.Environment Variable:
APP_STORE_API_KEY_IDApp Store Connect API Issuer ID.Environment Variable:
APP_STORE_API_ISSUER_IDYour app name in App Store Connect.Environment Variable:
APP_STORE_APP_NAMEPermissions
Enable or disable specific native features and define permission request messages:Array of permission keys mapped to boolean or string values.
true- Enable permission with default messagefalse- Disable permissionstring- Enable with custom iOS permission message
On iOS, custom permission messages are shown when requesting access. Android interprets any string value as
true but doesn’t display custom messages.cameralocationmicrophonenotificationsphoto_librarycontactscalendarremindersbluetoothmotionspeech_recognitionface_idnfc
Example Configuration
Here’s a complete example configuration for a production app:Next Steps
Architecture
Understand how NativePHP Mobile works
Native APIs
Explore available native APIs
Permissions
Learn about requesting permissions
Building Apps
Build your app for production