wx.miniapp.openUrl

View Markdown

Last edited on 2026-08-21

iOS >= 1.0.30, Android >= 1.0.19

Jump to a third-party App. Before using this interface to perform a jump, you must configure the relevant settings in the Multi-Platform App Console. For details, see the Operation Guide.

  • Note: If the url is HTTPS, it will be opened using the system's default browser, and this functionality does not require configuration in the Multi-Platform App Console.

Parameters

Attribute Type Default Required Description
url string Yes The target App path to navigate to. The Scheme prefix of this parameter must match the configuration in the Multi-Platform App Console

JSAPI Code Example

wx.miniapp.openUrl({
    url: "weixin://dl/moments",
    success(res) {
        console.log('wx.miniapp.openUrl success', res)
    },
    fail(err) {
        console.log('wx.miniapp.openUrl fail', err)
    }
})