Skip to main content
Review the DARO 2.0 SDK overview and common migration guide, then follow the steps below. See legacy SDK (before 2.0.0) support for the scope of support for earlier versions.
Existing Ad Unit IDs continue to work with the DARO 2.0 SDK and do not need to be reissued or replaced. For new integrations or when copying a value, use the Ad Unit Key from the updated dashboard. Keep existing Ad Unit IDs in app versions that use the legacy SDK (before 2.0.0); newly created Ad Unit keys do not work with that SDK. ID compatibility does not remove the need to review package, initialization, and ad API changes.
Your starting point depends on the package you use today.

1. Update the dashboard

  • In the DARO dashboard, select the app you are migrating and complete the update.
  • Find the Integration Key and Ad Unit Keys for the Android app and the iOS app separately.

2. Remove legacy key files and settings

  • Remove daro-services.json, daro-service.json, daro-key.txt, android-daro-key.txt, ios-daro-key.txt, and any settings that reference them. Also check file references registered in Xcode and the Copy Bundle Resources entries.
  • Remove the existing daroAppKey setting from android/gradle.properties and your build scripts.
  • If you used the Expo config plugin, remove daroAppKey, daroKeyFile, and admobAppId.
  • The DARO 2.0 SDK config plugin fails with an error and stops the prebuild if any of these three legacy settings remain.
  • admobAppId existed only in the iOS settings, so check it as well.

3. Configure DARO integration tools

  • If you used react-native-daro-m, remove it and install react-native-daro.
  • If you already use react-native-daro, update the same package.
  • The two packages pull in different native SDKs, so do not keep both.
  • Follow the Android migration guide and the iOS migration guide to prepare the build tools the new SDK requires.
  • Expo projects use the config plugin described in Get Started.
  • React Native CLI projects follow the manual setup in the same document.
  • Do not apply the previous plugin alongside the new one.
  • react-native-daro declares Expo 50 or later as a peer dependency.
  • On an earlier version, upgrade Expo first or use the React Native CLI manual setup.

4. Configure the Integration Key and app settings

  • Get the Integration Key for each platform’s app from the dashboard and configure it.
  • Use the key that belongs to each app for Android and iOS.
  • The Expo config plugin takes a single key per platform.
Before app.json
After app.json
  • Run npx expo prebuild only after replacing the package in step 3.
  • The react-native-daro plugin in app.json is resolved from node_modules. Running it while the legacy package is still installed loads the previous plugin, which cannot process the new settings.
  • After changing the configuration, run npx expo prebuild.
  • For manual integration, follow the platform settings in Get Started, and run pod install in the ios/ directory.

5. Update app-ads.txt

  • Follow the app-ads.txt guide and publish the latest content provided by the dashboard.
  • Confirm that the file is accessible on the website registered in the dashboard.

6. Update SDK dependencies and code

Update import paths

  • Update every import path that came from react-native-daro-m.

Remove placement

  • placement has been removed from ad creation arguments and from the banner and native components.

Move from the static ad API to the Hook or instance API

  • The static APIs for interstitial, rewarded, and light popup ads (InterstitialAd.loadAd and so on) still work the same way in the DARO 2.0 SDK, but they are deprecated.
  • Your app still builds if you move only some of the formats, so you can migrate one format at a time.
  • Static listeners (InterstitialAd.addAdLoadedEventListener and so on) do not receive events from ads loaded through the Hook or instance API.
  • When you move a format’s loading to the new API, move that format’s event listeners as well.
  • If you move only the loading and leave the listeners in place, the callbacks are never called.
Before — static API
After — Hook API
  • To manage an ad outside a component, use the instance API.
  • Registering a listener returns a function that removes it.
After — instance API

Initialization order

  • Load ads and render the banner and native components only after initialize() completes.
  • If your app sets consent states, call setGdpr, setCcpa, and setCoppa before initialize(). For child-directed apps, setCoppa must already be in effect for the initialization request itself.

Check each ad format

What you gain after migrating

  • Native ads, which react-native-daro-m did not provide, are now available.
  • AdInfo in the ad callbacks adds mediationPlatform and adNetwork, so you can see which ad demand source filled the ad. The existing fields are unchanged.
  • Native ads accept adChoicesPosition to set the preferred position of the AdChoices icon.

Verify before release

  • Rebuild the Android and iOS apps, then verify loading, display, dismissal, and callbacks on a real device for every ad format you use.
  • If you use rewarded video ads, verify the reward callback as well.
  • Keep the existing Ad Unit IDs in released versions that still use the legacy SDK (before 2.0.0).