App store link for “rate/review this app”

2019-01-01 09:39发布

I want to put a "rate/review this app" feature into my app.

Is there a way to link directly to the screen in the app store where they review the app? So the customer doesn't have to click through the main app link. Thanks.

EDIT: starting a bounty on this due to the lack of response. Just to make sure it is crystal clear: I am aware that I can link to my app's page in the store, and ask the user to click from there to the "review this app" screen. The question is whether it is possible to link directly to the "review this app" screen so they don't have to click through anything.

26条回答
刘海飞了
2楼-- · 2019-01-01 10:05

Swift 2 version that actually takes you to the review page for your app on both iOS 8 and iOS 9:

let appId = "YOUR_APP_ID"
let url = "itms-apps://itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?type=Purple+Software&id=\(appId)"

UIApplication.sharedApplication().openURL(NSURL(string: url)!)
查看更多
听够珍惜
3楼-- · 2019-01-01 10:08

For >= iOS8: (Simplified @EliBud's answer).

#define APP_STORE_ID 1108885113

- (void)rateApp{
    static NSString *const iOSAppStoreURLFormat = @"itms-apps://itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?type=Purple+Software&id=%d";

    NSURL *appStoreURL = [NSURL URLWithString:[NSString stringWithFormat:iOSAppStoreURLFormat, APP_STORE_ID]];

    if ([[UIApplication sharedApplication] canOpenURL:appStoreURL]) {
        [[UIApplication sharedApplication] openURL:appStoreURL];
    }
}
查看更多
十年一品温如言
4楼-- · 2019-01-01 10:09

Starting in iOS 10.3:

import StoreKit

func someFunction() {
 SKStoreReviewController.requestReview()
}

but its has been just released with 10.3, so you will still need some fallback method for older versions as described above

查看更多
柔情千种
5楼-- · 2019-01-01 10:11

EDIT: iOS 11 Solution

This is the solution to my original answer (see below). When using the iOS 11 the following link format will work:

https://itunes.apple.com/us/app/appName/idAPP_ID?mt=8&action=write-review

Simply replace APP_ID with your specific app ID. The key to make the link work is the country code. The link above uses the us code but it actually doesn't matter which code is used. The user will automatically be redirected to his store.

iOS 11 Update:

It seems that none of the solutions presented in the other answers to get directly to the Review Page works on iOS 11.

The problem most likely is, that an app page in the iOS 11 App Store app does NOT have a Review Tab anymore. Instead the reviews are now located directly below the description and the screenshots. Of course it could still be possible to reach this section directly (e.g. with some kind of anchor), but it seems that this is not supported / intended by Apple.

Using one of the following links does not work anymore. They still bring the users to the App Store app but only to a blank page:

itms-apps://itunes.apple.com/app/idYOUR_APP_ID?action=write-review
itms-apps://itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?id=YOUR_APP_ID&onlyLatestVersion=true&pageNumber=0&sortOrdering=1&type=Purple+Software

Everyone how still uses these links should update their apps ASAP, because referring the users to a blank App Store page is most likely not what you intended.

Links which do not refer to the Review page but to the App page, still work however, e.g.

itms-apps://itunes.apple.com/app/idYOUR_APP_ID   (same as above, but without write-review parameter)

So, you can still get the users to your apps Store page, but not directly to the review section anymore. Users now have to scroll down to the review section manually to leave their feedback.

Without a question this a "great and awesome benefit for User Experience and will help developers to engage users to leave high quality reviews without annoying them". Well done Apple...

查看更多
与风俱净
6楼-- · 2019-01-01 10:11

Link to any App in the AppStore via SKStoreProductViewController

It is easy to link to your app at the app store via SKStoreProductViewController. But I struggled a little bit, so I decided to show here the whole process and some code necessary. This technique also makes sure that always the correct store will be used (important for localized apps).

To present the product screen of any app of the app store within your app with any of your apps ViewControllers follow this steps:

  1. Add the StoreFit.framework in your project settings (Target, Build Phases -> Link Binary With Libraries
  2. Import StoreKit into the ViewController class
  3. Make your ViewController conforms this protocol SKStoreProductViewControllerDelegate
  4. Create the method to present the StoreView with the product screen you want
  5. Dismiss the StoreView

But most important: This - for some reason - does not work in the simulator - you have to build and install on a real device with internet connectivity.

  1. Adding the StorKit.framework to your project: Find this in your project settings

SWIFT 4: This is the code according to the described steps ahead:

    // ----------------------------------------------------------------------------------------
// 2. Import StoreKit into the ViewController class
// ----------------------------------------------------------------------------------------
import StoreKit

// ...

// within your ViewController

    // ----------------------------------------------------------------------------------------
    // 4. Create the method to present the StoreView with the product screen you want
    // ----------------------------------------------------------------------------------------
    func showStore() {

        // Define parameter for product (here with ID-Number)
        let parameter : Dictionary<String, Any> = [SKStoreProductParameterITunesItemIdentifier : NSNumber(value: 742562928)]

        // Create a SKStoreProduktViewController instance
        let storeViewController : SKStoreProductViewController = SKStoreProductViewController()

        // set Delegate
        storeViewController.delegate = self

        // load product
        storeViewController.loadProduct(withParameters: parameter) { (success, error) in

            if success == true {
                // show storeController
                self.present(storeViewController, animated: true, completion: nil)
            } else {
                print("NO SUCCESS LOADING PRODUCT SCREEN")
                print("Error ? : \(error?.localizedDescription)")
            }
        }
    }

// ...

// ----------------------------------------------------------------------------------------
// 3. Make your ViewController conforming the protocol SKStoreProductViewControllerDelegate
// ----------------------------------------------------------------------------------------
extension ViewController : SKStoreProductViewControllerDelegate {

    // ----------------------------------------------------------------------------------------
    // 5. Dismiss the StoreView
    // ----------------------------------------------------------------------------------------
    func productViewControllerDidFinish(_ viewController: SKStoreProductViewController) {
        print("RECEIVED a FINISH-Message from SKStoreProduktViewController")
        viewController.dismiss(animated: true, completion: nil)
    }
}
查看更多
公子世无双
7楼-- · 2019-01-01 10:12

Starting from iOS 10.3 you can attach action=write-review query item to your https://itunes.apple.com/... and https://appsto.re/... URLs. On iOS 10.3 and up it will open Write a review automatically, while on lower iOS releases will fall back to the app's App Store page.

iOS 11 update: Use Apple's linkmaker: linkmaker.itunes.apple.com and append &action=write-review, seems to be the most safe way to go.

查看更多
登录 后发表回答