Learn how to launch the Windows Settings app. This topic describes the ms-settings: URI scheme. Use this URI scheme to launch the Windows Settings app to specific settings pages.
Launching to the Settings app is an important part of writing a privacy-aware app. If your app can't access a sensitive resource, we recommend providing the user a convenient link to the privacy settings for that resource. For more information, see Security and identity.
Important APIs
The following Windows Runtime (WinRT) APIs are used in this topic:
Note that the WinRT APIs used in this topic can be used in both UWP apps, WinUI apps, and other desktop apps. To read more about enabling your desktop app to work with WinRT APIs, see Call Windows Runtime APIs in desktop apps.
How to launch the Settings app
To launch the Settings app, use the ms-settings: URI scheme as shown in the following examples.
XAML hyperlink control
In this example, a Hyperlink XAML control is used to launch the privacy settings page for the microphone using the ms-settings:privacy-microphone URI.
XML
<!--Set Visibility to Visible when access to the microphone is denied --><TextBlockx:Name="LocationDisabledMessage"FontStyle="Italic"Visibility="Collapsed"Margin="0,15,0,0"TextWrapping="Wrap" ><RunText="This app is not able to access the microphone. Go to " /><HyperlinkNavigateUri="ms-settings:privacy-microphone"><RunText="Settings" /></Hyperlink><RunText=" to check the microphone privacy settings."/></TextBlock>
Calling LaunchUriAsync
Alternatively, your app can call the LaunchUriAsync method to launch the Settings app. This example shows how to launch to the privacy settings page for the camera using the ms-settings:privacy-webcam URI.
cs
bool result = await Windows.System.Launcher.LaunchUriAsync(new Uri("ms-settings:privacy-webcam"));
C++/WinRT
bool result = co_await Windows::System::Launcher::LaunchUriAsync(Windows::Foundation::Uri(L"ms-settings:privacy-webcam"));
The code above launches the privacy settings page for the camera:
The availability of some settings pages varies by Windows version and SKU. For some settings, the URI column also captures some usage information and any additional requirements that must be met for a page to be available.
Accounts
Settings page
URI
Access work or school
ms-settings:workplace
Email & app accounts
ms-settings:emailandaccounts
Family & other people
ms-settings:otherusers
Provisioning
ms-settings:provisioning (only available on mobile and if the enterprise has deployed a provisioning package) ms-settings:workplace-provisioning (only available if enterprise has deployed a provisioning package)
ms-settings:appsfeatures-app (Reset, manage add-on & downloadable content, etc. for the app)
To access this page with a URI, use the ms-settings:appsfeatures-app URI and pass an optional parameter of the package family name of the app.
Example: ms-settings:appsfeatures-app?<PFN>
Apps for websites
ms-settings:appsforwebsites
Default apps
ms-settings:defaultapps (Behavior introduced in Windows 11, version 21H2 (with 2023-04 Cumulative Update) or 22H2 (with 2023-04 Cumulative Update), or later.) Append the query string parameter in the following formats using the Uri-escaped name of an app to directly launch the default settings page for that app:
- registeredAppMachine=<Uri-escaped per machine installed name of app> - registeredAppUser=<Uri-escaped per user installed name of app> - registeredAUMID=<Uri-escaped Application User Model ID>
Cortana voice assistance in Windows as a standalone app was retired in the spring of 2023. For more information, see End of support for Cortana.
Примечание
This Settings section on desktop will be called Search when the PC is set to regions where Cortana is not currently available or Cortana has been disabled. Cortana-specific pages (Cortana across my devices, and Talk to Cortana) will not be listed in this case.
Devices
Settings page
URI
AutoPlay
ms-settings:autoplay
Bluetooth
ms-settings:bluetooth
Connected Devices
ms-settings:connecteddevices
Default camera
ms-settings:camera (Behavior deprecated in Windows 10, version 1809 and later)
Camera settings
ms-settings:camera (Behavior introduced in Windows 11, build 22000 and later) Append the query string parameter cameraId set to the Uri-escaped symbolic link name of a camera device to directly launch the settings for that camera. For more information, see Launch the camera settings page.
Mouse & touchpad
ms-settings:mousetouchpad (touchpad settings only available on devices that have a touchpad)
Pen & Windows Ink
ms-settings:pen
Printers & scanners
ms-settings:printers
Touch
ms-settings:devices-touch
Touchpad
ms-settings:devices-touchpad (only available if touchpad hardware is present)
Text Suggestions
ms-settings:devicestyping-hwkbtextsuggestions
Typing
ms-settings:typing
USB
ms-settings:usb
Wheel
ms-settings:wheel (only available if a Surface Dial device is paired)
ms-settings:personalization-glance (Deprecated in Windows 10, version 1809 and later)
Lock screen
ms-settings:lockscreen
Navigation bar
ms-settings:personalization-navbar (Deprecated in Windows 10, version 1809 and later)
Personalization (category)
ms-settings:personalization
Start
ms-settings:personalization-start
Taskbar
ms-settings:taskbar
Text input
ms-settings:personalization-textinput
Touch Keyboard
ms-settings:personalization-touchkeyboard
Themes
ms-settings:themes
Phone
Settings page
URI
Your phone
ms-settings:mobile-devices ms-settings:mobile-devices-addphone ms-settings:mobile-devices-addphone-direct (Opens Your Phone app)
Device Usage
ms-settings:deviceusage
Privacy
Settings page
URI
Accessory apps
ms-settings:privacy-accessoryapps (Deprecated in Windows 10, version 1809 and later)
Account info
ms-settings:privacy-accountinfo
Activity history
ms-settings:privacy-activityhistory
Advertising ID
ms-settings:privacy-advertisingid (Deprecated in Windows 10, version 1809 and later)
App diagnostics
ms-settings:privacy-appdiagnostics
Automatic file downloads
ms-settings:privacy-automaticfiledownloads
Background Apps
ms-settings:privacy-backgroundapps (Deprecated in Windows 11, 21H2 and later)
Note: In Windows 11, the background app permissions are accessed individually. To view the permissions, go to Apps->Installed apps and then select "..." on a modern app and choose Advanced options. The advanced page is present for modern apps, and the Background apps permissions section will be present unless a group policy has been set or the user’s global toggle value (the deprecated setting from Windows 10) is set. To access this page with a URI, use the ms-settings:appsfeatures-app URI and pass an optional parameter of the package family name of the app.
ms-settings:regionlanguage-chsime-pinyin (available if the Microsoft Pinyin input method editor is installed) ms-settings:regionlanguage-chsime-pinyin-domainlexicon ms-settings:regionlanguage-chsime-pinyin-keyconfig ms-settings:regionlanguage-chsime-pinyin-udp
Speech
ms-settings:speech
Wubi IME settings
ms-settings:regionlanguage-chsime-wubi (available if the Microsoft Wubi input method editor is installed)
Update and security
Settings page
URI
Activation
ms-settings:activation
Backup
ms-settings:backup (page removed in Windows 11; opens Sync)
Источник этого содержимого можно найти на GitHub, где также можно создавать и просматривать проблемы и запросы на вытягивание. Дополнительные сведения см. в нашем руководстве для участников.
Отзыв о Windows developer
Windows developer — это проект с открытым исходным кодом. Выберите ссылку, чтобы оставить отзыв:
Планирование и выполнение стратегии развертывания конечных точек с помощью основных элементов современного управления, совместного управления и интеграции Microsoft Intune.