Android 11은 앱의 기능이 백그라운드 위치에 액세스할 수 있는 방법을 변경합니다. 이 섹션에서는 이러한 각 변경사항을 설명합니다.
앱의 기능이 백그라운드에서 위치에 액세스하면 이러한 액세스가 필요한지 확인합니다. 백그라운드에서 위치에 액세스하는 방법에 관한 페이지에 설명된 대로 기능에 필요한 정보를 다른 방법으로 얻는 것을 고려하세요.
별도로 백그라운드 위치 요청
런타임 시 위치 액세스를 요청하는 방법에 관한 가이드에 설명된 대로 증분 위치 요청을 실행해야 합니다. 앱이 Android 11 이상을 타겟팅하면 시스템에서는 이 권장사항을 적용합니다. 포그라운드 위치 정보 액세스 권한과 백그라운드 위치 정보 액세스 권한을 동시에 요청하면 시스템이 요청을 무시하고 앱에 어떤 권한도 부여하지 않습니다.
권한 대화상자 변경사항
변경 세부정보
변경 이름: BACKGROUND_RATIONALE_CHANGE_ID
변경 ID: 147316723
전환하는 방법
앱과 Android 11의 호환성을 테스트할 때 다음 ADB 명령어를 사용하여 이 변경사항을 사용 설정하거나 사용 중지할 수 있습니다.
adb shell am compat enable (147316723|BACKGROUND_RATIONALE_CHANGE_ID) PACKAGE_NAMEadb shell am compat disable (147316723|BACKGROUND_RATIONALE_CHANGE_ID) PACKAGE_NAME
앱의 기능이 Android 11 이상을 실행하는 기기에서 백그라운드 위치를 요청하면 시스템 대화상자에 백그라운드 위치 액세스를 사용 설정하는 버튼이 포함되지 않습니다. 백그라운드 위치 액세스를 사용 설정하려면 사용자는 백그라운드 위치 요청 방법에 관한 가이드에 설명된 대로 설정 페이지에서 앱의 위치 정보 액세스 권한의 항상 허용 옵션을 설정해야 합니다.
이 페이지에 나와 있는 콘텐츠와 코드 샘플에는 콘텐츠 라이선스에서 설명하는 라이선스가 적용됩니다. 자바 및 OpenJDK는 Oracle 및 Oracle 계열사의 상표 또는 등록 상표입니다.
최종 업데이트: 2025-08-21(UTC)
[null,null,["최종 업데이트: 2025-08-21(UTC)"],[],[],null,["# Location updates in Android 11\n\nTo further protect user privacy, Android 11 adds one-time\nlocation access and changes how users grant background location access. These\nupdates affect all apps that run on Android 11 and higher.\n\nOne-time access\n---------------\n\n**Figure 1.** System dialog for the foreground location permission includes an option called **Only this time**.\n\nOn Android 11 and higher, whenever your app requests access to\n[foreground location](/training/location/permissions#foreground), the system\npermissions dialog includes an option called **Only this time**, as shown in\nfigure 1. This option give users more control over when an app can access\nlocation information.\n\nLearn more about how the system handles [one-time\npermissions](/guide/topics/permissions/overview#one-time).\n\nBackground location access\n--------------------------\n\nAndroid 11 changes how a feature in your app can gain access to\n[background location](/training/location/permissions#background). This section\ndescribes each of these changes.\n\nIf a feature in your app accesses location from the background, verify that such\naccess is necessary. Consider getting the information that the feature needs in\nother ways, as described on the page about how to [access\nlocation in the background](/training/location/background).\n\n### Request background location separately\n\nAs described in the guide on how to [request location access at\nruntime](/training/location/permissions#request-location-access-runtime), you\nshould perform incremental location requests. If your app targets\nAndroid 11 or higher, the system enforces this best practice. If\nyou request a foreground location permission and the background location\npermission at the same time, the system ignores the request and doesn't grant\nyour app either permission.\n\n### Permission dialog changes\n\n### Change details\n\n**Change Name** : `BACKGROUND_RATIONALE_CHANGE_ID`\n\n**Change ID** : `147316723`\n\n### How to toggle\n\nAs you test your app's compatibility with Android 11, you can toggle this change on or off\nusing the following ADB commands: \n\n adb shell am compat enable (\u003cvar translate=\"no\"\u003e147316723\u003c/var\u003e|\u003cvar translate=\"no\"\u003eBACKGROUND_RATIONALE_CHANGE_ID\u003c/var\u003e) \u003cvar translate=\"no\"\u003ePACKAGE_NAME\u003c/var\u003e\n adb shell am compat disable (\u003cvar translate=\"no\"\u003e147316723\u003c/var\u003e|\u003cvar translate=\"no\"\u003eBACKGROUND_RATIONALE_CHANGE_ID\u003c/var\u003e) \u003cvar translate=\"no\"\u003ePACKAGE_NAME\u003c/var\u003e\n\nFor more information about the compatibility framework and toggling changes, see\n[Test and debug platform behavior changes in\nyour app](/guide/app-compatibility/test-debug).\n\nWhen a feature in your app requests background location on a device that runs\nAndroid 11 or higher, the system dialog doesn't include a button\nto enable background location access. In order to enable background location\naccess, users must set the **Allow all the time** option for your app's location\npermission on a settings page, as described in the guide on how to [Request\nbackground location](/training/location/permissions#request-background-location).\n\n### Additional resources\n\nFor more information about accessing background location, view the following\nmaterials:\n\n#### Videos\n\n- [How to find possible background location\n usage](https://www.youtube.com/watch?v=xTVeFJZQ28c)"]]