Logging

Configure log levels to control how the Airship SDK logs messages.

The Airship SDK provides configurable log levels to help you debug issues without overwhelming the console. By default, the log level is set to Info for development builds and Error for production builds to ensure clean logs in a live environment.

Log levels

The following log levels are available, ordered from most to least verbose.

Log LevelDescription
VerboseReports highly detailed SDK status, which is useful for deep debugging and troubleshooting.
DebugReports general SDK status with more detailed information than Info.
InfoReports general SDK status and lifecycle events.
WarningUsed for API deprecations, invalid setup, and other potentially problematic situations that are generally recoverable.
ErrorUsed for critical errors, exceptions, and other situations that the SDK cannot gracefully handle.
AssertDisables all logging.

Configuring log levels

You can set the log level in the Airship config files for Android and iOS.

Android

In your airshipconfig.properties file:

# Available log levels: VERBOSE, DEBUG, INFO, WARN, ERROR, ASSERT
productionLogLevel = VERBOSE
developmentLogLevel = VERBOSE

iOS

In your AirshipConfig.plist file:

<!--  Available log levels: TRACE, DEBUG, INFO, WARNING, NONE -->
<key>productionLogLevel</key>
<string>TRACE</string>
<key>developmentLogLevel</key>
<string>TRACE</string>