App Store linking
mobile app links
app deep linking
iOS app links
app marketing tips

How to link to an app on the App Store (URL formats)

Codemia Knowledge Hub ·

Link to an App Store page with https://apps.apple.com/app/id<APP_ID>, where the ID is the app's numeric App Store ID. That HTTPS form is best for websites, messages and email. Inside an iOS app, the itms-apps scheme opens the App Store app directly, and SKStoreProductViewController shows the store page without leaving your app.

The HTTPS App Store URL

This works in browsers, on mobile devices and on desktop:

text
https://apps.apple.com/app/id1234567890

Apple also supports URLs that include the app name slug:

text
https://apps.apple.com/us/app/example-app/id1234567890

The numeric app ID is the important, stable part of the URL.

Opening the App Store from an iOS app with itms-apps

swift
1import UIKit
2
3func openAppStore(appID: String) {
4    guard let url = URL(string: "itms-apps://itunes.apple.com/app/id\(appID)") else {
5        return
6    }
7
8    UIApplication.shared.open(url)
9}

itms-apps skips the browser and usually opens the App Store app directly, which suits upgrade prompts and "rate this app" flows.

On a website, in documentation or in cross-platform UI, prefer HTTPS. It is more portable and degrades more gracefully outside iOS:

swift
1import UIKit
2
3func openStoreWebURL(appID: String) {
4    guard let url = URL(string: "https://apps.apple.com/app/id\(appID)") else {
5        return
6    }
7
8    UIApplication.shared.open(url)
9}

Show the store page inside your app

SKStoreProductViewController keeps the user in your app flow, which is useful for upgrade nudges:

swift
1import StoreKit
2import UIKit
3
4final class StorePresenter: NSObject, SKStoreProductViewControllerDelegate {
5    func showStorePage(from viewController: UIViewController, appID: Int) {
6        let storeVC = SKStoreProductViewController()
7        storeVC.delegate = self
8
9        storeVC.loadProduct(withParameters: [SKStoreProductParameterITunesItemIdentifier: appID]) { loaded, error in
10            if loaded {
11                viewController.present(storeVC, animated: true)
12            } else {
13                print(error?.localizedDescription ?? "Failed to load App Store page")
14            }
15        }
16    }
17
18    func productViewControllerDidFinish(_ viewController: SKStoreProductViewController) {
19        viewController.dismiss(animated: true)
20    }
21}

Storefront regions

App Store URLs often include a storefront region such as /us/ or /gb/. Without one, Apple can often resolve the right storefront automatically, but region-specific links are common in marketing material. If your app is only in certain storefronts, test the link there before shipping campaigns or in-app prompts.

The app ID is not the bundle identifier

The app ID is the numeric identifier assigned in App Store Connect:

  • bundle identifier: com.example.myapp
  • App Store ID: 1234567890

Mixing these up is a common cause of broken links.

Linking to ratings and reviews

A direct review-page link is possible, but its URL pattern is more brittle than the main app page. For in-app review prompts, SKStoreReviewController is usually the better API where supported. In short:

  • app page link for install or upgrade
  • SKStoreProductViewController for in-app store display
  • SKStoreReviewController for rating prompts

Mistakes to avoid

  • Using the bundle identifier where the numeric App Store ID is required.
  • Using itms-apps where a normal web URL would be more portable.
  • Sending users out of the app when an in-app store sheet would be a better experience.
  • Hard-coding a storefront region without checking the app is available there.
  • Treating rating prompts and store-page links as the same problem.

Free course
Beginner
7 lessons
2 hours
Tackling System Design Interview Problems

A short course that equips you with the skills to approach system design interviews methodically.

Start the free course
Basis Lab
No course covers this one yet

Basis Lab writes one for you from a sentence about what you want to be able to do, then teaches it and checks you understood. Your first course is free.

Build my course
Data Structures & Algorithms practice on Codemia

Step through 300+ coding interview problems with animated visualisers that show the data structure changing as the code runs. The Blind 75 are free.

Practice algorithms