Pawan N Rao
Pawan N Rao

Reputation: 11

Spotify Deep link URI not working on Android Platform

I am trying to open Spotify URI link on my Android (HTC One) but it doesnt seem to be opening appropriately. The URI is just taking me into Spotify App without really redirecting me to the playlist the URI is pointing to? This is the URI: spotify://spotify:artist:12Chz98pHFMPJEknJQMWvI. Any help would be appreciated

Upvotes: 1

Views: 1178

Answers (2)

naXa stands with Ukraine
naXa stands with Ukraine

Reputation: 37993

In 2023, all these links behave like deep links to content inside Spotify app for Android (web-to-app). Please copy my code snippet somewhere and see for yourself (it doesn't work here just because the code on StackOverflow is sandboxed).

The 4th and 5th links are regular HTTPS URLs, and they open a webpage on desktop, but they act like deep links on Android (assuming the Spotify app is installed).

<link href="https://cdn.jsdelivr.net/npm/[email protected]/font/bootstrap-icons.min.css" rel="stylesheet" />
<table border="1">
  <thead>
    <tr>
      <th>URL</th>
      <th>As plain text</th>
      <th>Compatibility</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a href="spotify:artist:12Chz98pHFMPJEknJQMWvI">Spotify URI</a></td>
      <td>spotify:artist:</td>
      <td><i class="bi bi-android"></i> <i class="bi bi-apple"></i> <i class="bi bi-windows"></i></td>
    </tr>

    <tr>
      <td><a href="spotify://artist/12Chz98pHFMPJEknJQMWvI">Spotify protocol</a></td>
      <td>spotify://artist/</td>
      <td><i class="bi bi-android"></i> <i class="bi bi-apple"></i> <i class="bi bi-windows"></i></td>
    </tr>

    <tr>
      <td><a href="intent://artist/12Chz98pHFMPJEknJQMWvI#Intent;package=com.spotify.music;scheme=spotify;end">Spotify Android Intent</a></td>
      <td>intent://artist/...#Intent;...</td>
      <td><i class="bi bi-android"></i></td>
    </tr>

    <tr>
      <td><a target="_blank" href="https://open.spotify.com/artist/12Chz98pHFMPJEknJQMWvI" target="_blank">HTTP Spotify URL</a></td>
      <td>https://open.spotify.com/artist/</td>
      <td><i class="bi bi-android"></i> <i class="bi bi-browser-chrome"></i> <i class="bi bi-browser-edge"></i> <i class="bi bi-browser-firefox"></i> <i class="bi bi-browser-safari"></i></td>
    </tr>

    <tr>
      <td><a href="https://spotify.link/content_linking?~campaign=jsfiddle&$deeplink_path=spotify:artist:12Chz98pHFMPJEknJQMWvI&$fallback_url=https://open.spotify.com/artist/12Chz98pHFMPJEknJQMWvI" target="_blank">Deep Link with Fallback</a></td>
      <td>https://spotify.link/content_linking/...</td>
      <td><i class="bi bi-android"></i> <i class="bi bi-browser-chrome"></i> <i class="bi bi-browser-edge"></i> <i class="bi bi-browser-firefox"></i> <i class="bi bi-browser-safari"></i></td>
    </tr>
  </tbody>
</table>

See the same code in jsFiddle.

Documentation:

Upvotes: 0

iKenndac
iKenndac

Reputation: 18776

Just open spotify:artist:12Chz98pHFMPJEknJQMWvI - the spotify:// part isn't required, and isn't part of the Spotify URI spec.

Upvotes: 1

Related Questions