---
updatedAt: 2026-07-27T10:20:41.000Z
agentTools:
  projectIndex: https://developers.dailymotion.com/v0/llms.txt
---

# iOS SDK Migration guide

This guide is intended to help you migrate from the legacy native SDK to our **[new iOS SDK](https://developers.dailymotion.com/v0/docs/getting-started-with-the-ios-sdk)**.

> ❗️ Sunset notice legacy SDK:
>
> As of February 3rd 2026, the [legacy iOS SDK has been sunset](https://developers.dailymotion.com/v0/reference/migration-guide-new-embed-endpoint#-legacy-native-sdks) and is no longer supported.
>
> To avoid any disruption, it is required for all Partners still using it to **migrate to the new iOS SDK following guidelines below.**
>
> If you have questions or need assistance, please reach out to our [Support team](https://faq.dailymotion.com/hc/requests/new).

<br />

# Overview

<Table align={["left","left"]}>
  <thead>
    <tr>
      <th>

      </th>

      <th>

      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        **New repository**
      </td>

      <td>
        * New iOS SDK available on [GitHub](https://github.com/dailymotion/player-sdk-ios)
      </td>
    </tr>

    <tr>
      <td>
        **Sample applications**
      </td>

      <td>
        * [**iOS sample app:**](https://app.bitrise.io/installable-artifacts/fac7df83-66f2-89ca-969f-3e1c159de079/public-install-page/76c71fde556c89082d4d38ab9d0b548a) Download the sample app on your device and explore the SDK functionalities in a user-friendly UI
        * [**Source code:**](https://github.com/dailymotion/player-sdk-ios-samples/) Access the sample app source code, customize it as you wish and easily integrate the SDK into your projects
      </td>
    </tr>

    <tr>
      <td>
        **Key features**
      </td>

      <td>
        * Remote Player management
        * iOS 18 support
        * Verified Google IMA integration
        * OMSDK support
        * Sample Player applications & code samples
        * Fullscreen playback management
        * Access to Player events and state facilitated
        * Chromecast support
      </td>
    </tr>

    <tr>
      <td>
        **Minimum supported versions**
      </td>

      <td>
        Swift 5+  
        iOS 14+  
        Xcode 14+
      </td>
    </tr>
  </tbody>
</Table>

<br />

# Implementation resources

<Cards>
  <Card title="Getting started with the iOS SDK" href="https://developers.dailymotion.com/v0/docs/getting-started-with-the-ios-sdk" icon="fa-rocket" />

  <Card title="SDK Reference" href="https://developers.dailymotion.com/v0/reference/ios-sdk-player-methods" icon="fa-code" />
</Cards>

<br />

# Benefits

**Key benefits of the new iOS SDK:**

* **More customization:** The new iOS SDK offers more customization options and greater flexibility in managing Player configurations via the [Studio](https://www.dailymotion.com/partner/embed/players). Embedding and controlling your Players is easier and more efficient thanks to Player IDs.
* **Better monetization:** The new SDK complies with Google IMA standards and TCF2 to help you handle monetization more effectively
* **Improved developer experience:** The new SDK provides an easier way to embed and control custom Players, and simplified access to various data

<br />

***

<br />

# Integration principles

Find the **key technical steps** required to use our new iOS SDK the best way and benefit from improved functionalities and flexibility compared to the legacy one.

<br />

## Player customization

While the legacy SDK could only offer limited customization options and control, the **new SDK is built around Player IDs**. They carry your **Player configuration**, providing more flexibility and control over the Player’s behavior and appearance without requiring heavy customization within your code:

* **Manage from Studio:** You can easily create and manage custom Player configurations from the [Dailymotion Studio.](https://www.dailymotion.com/partner/embed/players)
* **Embed Player IDs:** Each Player configuration is linked to a **unique Player ID** which is required for **Player initialization** in your iOS app, and **accurate monetization, targeting and attribution**.
* **Optimize with API:** Additional customization can be added programmatically using the [Player methods, events and states](https://developers.dailymotion.com/v0/reference/ios-sdk-player-methods).

Learn more about how to [create and manage Players from the Studio](https://faq.dailymotion.com/hc/articles/4408224350994).

<br />

## Advertising dependencies

The IMA SDK is already integrated into the new SDK, however, it **requires declaring additional dependencies** to load the IMA libraries.

The [Swift Package Manager](https://swift.org/package-manager/) can be used to access the SDK. Specify the git URL for Dailymotion iOS SDK: <https://github.com/dailymotion/player-sdk-ios>

> 📘 Included libraries:
>
> * Dailymotion Advertising SDK
> * Google IMA
> * OM SDK

<br />

## Handling advertising set up

In order to benefit from accurate monetization, make sure to implement the following steps:

1. Create a dedicated Player config for your iOS app from your [Dailymotion Studio](https://faq.dailymotion.com/hc/en-us/articles/4408224350994) or via the [API](https://developers.dailymotion.com/v0/reference/partner-api-create-a-player), and use the generated Player ID in the Player initialization method.
2. Publishers in GDPR countries are required to implement a **TCF2-registered CMP** in their native app to ensure monetization. **Collect consent from CMP before loading the Player.**
3. Implementing `DMPlayerDelegate` is mandatory, see [here](https://developers.dailymotion.com/v0/docs/getting-started-with-the-ios-sdk#implement-dmplayerdelegate).
4. Implement the necessary methods to ensure your application can manage the Player in all contexts, see [here](https://developers.dailymotion.com/v0/docs/getting-started-with-the-ios-sdk#required-configuration-methods).
5. Pass in and update custom advertising values. To learn more please see [here](https://developers.dailymotion.com/v0/docs/custom-config#implement-customconfig-with-ios-sdk).

<br />

## Fullscreen management

The new iOS SDK provides an **out-of-the-box fullscreen implementation** as well as a **custom fullscreen implementation**.

See how to [implement fullscreen with the new SDK](https://developers.dailymotion.com/v0/docs/out-of-the-box-fullscreen-implementation-ios-sdk).

<br />

## Destroy/release Player

The Player instance will be automatically destroyed and removed when there are no more references to the `DMPlayerView` object, and when the Automatic Reference Counting (ARC) counter reaches zero.

***

<br />

# Mapping

This section provides a mapping of the methods, events and state from the legacy SDK to the new iOS SDK to help you update your integration.

<br />

## Methods

<Table align={["left","left"]}>
  <thead>
    <tr>
      <th>
        Legacy iOS methods
      </th>

      <th>
        New iOS methods
      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        `initialize()`
      </td>

      <td>
        `Dailymotion.createPlayer(playerId: "PLAYERID", videoId: "VIDEOID", playerParameters: DMPlayerParameters() , playerDelegate: self)`
      </td>
    </tr>

    <tr>
      <td>
        `load(params: String)`
      </td>

      <td>
        `load​Content(video​Id:​playlist​Id:​start​Time:​)`
      </td>
    </tr>

    <tr>
      <td>
        `play()`
      </td>

      <td>
        `play()`
      </td>
    </tr>

    <tr>
      <td>
        `pause()`
      </td>

      <td>
        `pause()`
      </td>
    </tr>

    <tr>
      <td>
        `toggleFullscreen()`
      </td>

      <td>
        `setFullscreen()`  
        [Learn more](https://developers.dailymotion.com/v0/docs/out-of-the-box-fullscreen-implementation-ios-sdk)
      </td>
    </tr>

    <tr>
      <td>
        `unmute()`
      </td>

      <td>
        `setMute(mute:)`
      </td>
    </tr>

    <tr>
      <td>
        `mute()`
      </td>

      <td>
        `setMute(mute:)`
      </td>
    </tr>

    <tr>
      <td>
        `seek()`
      </td>

      <td>
        `seek(to:)`
      </td>
    </tr>

    <tr>
      <td>
        `toggleControls()`
      </td>

      <td>
        No longer supported. Ad and playback controls are now managed in Player configuration.
      </td>
    </tr>
  </tbody>
</Table>

Find the [complete list of methods for the new iOS SDK](https://developers.dailymotion.com/v0/reference/ios-sdk-player-methods).

<br />

## Events

<Table align={["left","left","left"]}>
  <thead>
    <tr>
      <th>
        Description
      </th>

      <th>
        Legacy events
      </th>

      <th>
        New events
      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        Sent when the Player is ready to accept API commands. Do not try to call functions before receiving this event.
      </td>

      <td>
        `apiready`
      </td>

      <td>
        Managed via `createPlayer()` method
      </td>
    </tr>

    <tr>
      <td>
        Sent the first time the Player attempts to start the playback, either because of user interaction, an autoplay parameter or an API call (e.g `play()`, `load()`, etc.).
      </td>

      <td>
        `start`
      </td>

      <td>
        `playerDidStart`
      </td>
    </tr>

    <tr>
      <td>
        Sent when playback of the content video, and eventual post-roll ad video, is completed.
      </td>

      <td>
        `VideoEndEvent`
      </td>

      <td>
        `playerDidEnd`
      </td>
    </tr>

    <tr>
      <td>
        Sent when the Player triggers an error. See all [error codes](https://developers.dailymotion.com/v0/reference/api-errors#error-codes).
      </td>

      <td>
        `error`
      </td>

      <td>
        `player(_:didFailWithError:)`
      </td>
    </tr>

    <tr>
      <td>
        Sent when the Player enters or exits the fullscreen state.
      </td>

      <td>
        `fullscreenchange`
      </td>

      <td>
        * [Built-in fullscreen behavior](https://developers.dailymotion.com/v0/docs/out-of-the-box-fullscreen-implementation-ios-sdk)
        * [Custom integration](https://developers.dailymotion.com/v0/docs/custom-fullscreen-implementation-ios-sdk) with `playerDidRequestFullscreen`
          and
          `playerDidExitFullScreen`
      </td>
    </tr>

    <tr>
      <td>
        Sent every time a video is ready to play, or started playing (depending on autoplay settings, and their resolution by the browser), or is unable to play (blocked, restricted, unavailable). Listen to this event if you want to defer doing network-heavy and JavaScript-heavy work, to allow the optimal delivery of the first frames of the video to the use.
      </td>

      <td>
        `playback_ready`
      </td>

      <td>
        `playerDidCriticalPathReady(_:)`
      </td>
    </tr>

    <tr>
      <td>
        Sent when the Player starts to seek to another position in the video timeline.
      </td>

      <td>
        `seeking`
      </td>

      <td>
        `video(_:didSeekStart:)`
      </td>
    </tr>

    <tr>
      <td>
        Sent when the Player has completed a seeking operation.
      </td>

      <td>
        `seeked`
      </td>

      <td>
        `video(_:didSeekEnd:)`
      </td>
    </tr>

    <tr>
      <td>
        Sent when a new video has been loaded in the Player. (e.g. after calling `load(videoId, [params])`, or at player start-up).
      </td>

      <td>
        `videochange`
      </td>

      <td>
        `player(_:didChangeVideo:)`
      </td>
    </tr>

    <tr>
      <td>
        Sent when the volume or mute state changes.
      </td>

      <td>
        `volumechange`
      </td>

      <td>
        `player(_:didChangeVolume:_:)`
      </td>
    </tr>
  </tbody>
</Table>

Find the [complete list of events for the new iOS SDK](https://developers.dailymotion.com/v0/reference/ios-sdk-player-events).

<br />

## Player state and properties

* **Legacy SDK**

The legacy SDK provided limited access to Player properties: it required specific events to be triggered to be able to retrieve associated Player properties

```swift
func player(_ player: DMPlayerViewController, didReceiveEvent event: PlayerEvent) {
    switch event {
    case .namedEvent(let name, let data):
        print("\(name) - \(data)")
    case .timeEvent(let name, let position):
        print("\(name) - \(position)")
```

<br />

* **New SDK**

The new iOS SDK provides **more data with easier access**: any value in the Player state can be retrieved at any time using the `getState(completion:)` method, without having to rely on specific events.

```swift
self.dmPlayerView?.getState(completion: { [weak self] (playerState) in
     print("playerIsPlaying : \(playerState?.playerIsPlaying)")
     print("videoId : \(playerState?.videoId)")
     print("playerError : \(playerState?.playerError)")
})
```

See full list of available [state properties](https://developers.dailymotion.com/v0/reference/ios-sdk-player-states).

<br />

> 📘 If you need assistance with the migration:
>
> Please reach out to your dedicated Dailymotion Account Manager or our [Support team](https://faq.dailymotion.com/hc/requests/new)

<br />

<br />