diff --git a/src/com/android/settings/MasterClearConfirm.java b/src/com/android/settings/MasterClearConfirm.java
index a8c4341..679f18f 100644
--- a/src/com/android/settings/MasterClearConfirm.java
+++ b/src/com/android/settings/MasterClearConfirm.java
@@ -49,6 +49,7 @@
 import com.google.android.setupcompat.template.FooterBarMixin;
 import com.google.android.setupcompat.template.FooterButton;
 import com.google.android.setupcompat.template.FooterButton.ButtonType;
+import com.google.android.setupcompat.util.WizardManagerHelper;
 import com.google.android.setupdesign.GlifLayout;
 
 /**
@@ -86,7 +87,7 @@
                     getActivity().getSystemService(Context.OEM_LOCK_SERVICE);
 
             if (pdbManager != null && !oemLockManager.isOemUnlockAllowed() &&
-                    Utils.isDeviceProvisioned(getActivity())) {
+                    WizardManagerHelper.isDeviceProvisioned(getActivity())) {
                 // if OEM unlock is allowed, the persistent data block will be wiped during FR
                 // process. If disabled, it will be wiped here, unless the device is still being
                 // provisioned, in which case the persistent data block will be preserved.
diff --git a/src/com/android/settings/SettingsActivity.java b/src/com/android/settings/SettingsActivity.java
index 4d813d5..b489bc4 100644
--- a/src/com/android/settings/SettingsActivity.java
+++ b/src/com/android/settings/SettingsActivity.java
@@ -276,7 +276,7 @@
             launchSettingFragment(initialFragmentName, intent);
         }
 
-        final boolean deviceProvisioned = Utils.isDeviceProvisioned(this);
+        final boolean deviceProvisioned = WizardManagerHelper.isDeviceProvisioned(this);
 
         final ActionBar actionBar = getActionBar();
         if (actionBar != null) {
diff --git a/src/com/android/settings/Utils.java b/src/com/android/settings/Utils.java
index 75db3e1..aef0ac8 100644
--- a/src/com/android/settings/Utils.java
+++ b/src/com/android/settings/Utils.java
@@ -73,7 +73,6 @@
 import android.provider.ContactsContract.Data;
 import android.provider.ContactsContract.Profile;
 import android.provider.ContactsContract.RawContacts;
-import android.provider.Settings;
 import android.telephony.SubscriptionManager;
 import android.telephony.TelephonyManager;
 import android.text.Spannable;
@@ -729,11 +728,6 @@
         }
     }
 
-    public static boolean isDeviceProvisioned(Context context) {
-        return Settings.Global.getInt(context.getContentResolver(),
-                Settings.Global.DEVICE_PROVISIONED, 0) != 0;
-    }
-
     public static boolean startQuietModeDialogIfNecessary(Context context, UserManager um,
             int userId) {
         if (um.isQuietModeEnabled(UserHandle.of(userId))) {
diff --git a/src/com/android/settings/development/DevelopmentSettingsDashboardFragment.java b/src/com/android/settings/development/DevelopmentSettingsDashboardFragment.java
index 52a5cd9..8e8a82d 100644
--- a/src/com/android/settings/development/DevelopmentSettingsDashboardFragment.java
+++ b/src/com/android/settings/development/DevelopmentSettingsDashboardFragment.java
@@ -53,6 +53,8 @@
 import com.android.settingslib.development.SystemPropPoker;
 import com.android.settingslib.search.SearchIndexable;
 
+import com.google.android.setupcompat.util.WizardManagerHelper;
+
 import java.util.ArrayList;
 import java.util.List;
 
@@ -166,7 +168,7 @@
         super.onActivityCreated(icicle);
         // Apply page-level restrictions
         setIfOnlyAvailableForAdmins(true);
-        if (isUiRestricted() || !Utils.isDeviceProvisioned(getActivity())) {
+        if (isUiRestricted() || !WizardManagerHelper.isDeviceProvisioned(getActivity())) {
             // Block access to developer options if the user is not the owner, if user policy
             // restricts it, or if the device has not been provisioned
             mIsAvailable = false;
diff --git a/src/com/android/settings/deviceinfo/BuildNumberPreferenceController.java b/src/com/android/settings/deviceinfo/BuildNumberPreferenceController.java
index dd522bf..40e34c0 100644
--- a/src/com/android/settings/deviceinfo/BuildNumberPreferenceController.java
+++ b/src/com/android/settings/deviceinfo/BuildNumberPreferenceController.java
@@ -46,6 +46,8 @@
 import com.android.settingslib.core.lifecycle.events.OnStart;
 import com.android.settingslib.development.DevelopmentSettingsEnabler;
 
+import com.google.android.setupcompat.util.WizardManagerHelper;
+
 public class BuildNumberPreferenceController extends BasePreferenceController implements
         LifecycleObserver, OnStart {
 
@@ -131,7 +133,7 @@
         }
 
         // Don't enable developer options until device has been provisioned
-        if (!Utils.isDeviceProvisioned(mContext)) {
+        if (!WizardManagerHelper.isDeviceProvisioned(mContext)) {
             mMetricsFeatureProvider.action(
                     mContext, SettingsEnums.ACTION_SETTINGS_BUILD_NUMBER_PREF);
             return false;
diff --git a/src/com/android/settings/password/ChooseLockGeneric.java b/src/com/android/settings/password/ChooseLockGeneric.java
index a2885d6..6809f35 100644
--- a/src/com/android/settings/password/ChooseLockGeneric.java
+++ b/src/com/android/settings/password/ChooseLockGeneric.java
@@ -36,12 +36,8 @@
 import android.app.settings.SettingsEnums;
 import android.content.Context;
 import android.content.Intent;
-import android.content.pm.UserInfo;
-import android.hardware.face.Face;
 import android.hardware.face.FaceManager;
-import android.hardware.fingerprint.Fingerprint;
 import android.hardware.fingerprint.FingerprintManager;
-import android.hardware.fingerprint.FingerprintManager.RemovalCallback;
 import android.os.Bundle;
 import android.os.UserHandle;
 import android.os.UserManager;
@@ -76,7 +72,7 @@
 import com.android.settingslib.RestrictedLockUtilsInternal;
 import com.android.settingslib.RestrictedPreference;
 
-import java.util.List;
+import com.google.android.setupcompat.util.WizardManagerHelper;
 
 public class ChooseLockGeneric extends SettingsActivity {
     public static final String CONFIRM_CREDENTIALS = "confirm_credentials";
@@ -188,7 +184,8 @@
         public void onCreate(Bundle savedInstanceState) {
             super.onCreate(savedInstanceState);
             final Activity activity = getActivity();
-            if (!Utils.isDeviceProvisioned(activity) && !canRunBeforeDeviceProvisioned()) {
+            if (!WizardManagerHelper.isDeviceProvisioned(activity)
+                    && !canRunBeforeDeviceProvisioned()) {
                 Log.i(TAG, "Refusing to start because device is not provisioned");
                 activity.finish();
                 return;
diff --git a/src/com/android/settings/password/SetNewPasswordActivity.java b/src/com/android/settings/password/SetNewPasswordActivity.java
index 055e5be..4bffbf5 100644
--- a/src/com/android/settings/password/SetNewPasswordActivity.java
+++ b/src/com/android/settings/password/SetNewPasswordActivity.java
@@ -32,16 +32,16 @@
 import android.app.admin.PasswordMetrics;
 import android.app.settings.SettingsEnums;
 import android.content.ComponentName;
-import android.content.Context;
 import android.content.Intent;
 import android.os.Bundle;
 import android.os.IBinder;
 import android.util.Log;
 
-import com.android.settings.Utils;
 import com.android.settings.overlay.FeatureFactory;
 import com.android.settingslib.core.instrumentation.MetricsFeatureProvider;
 
+import com.google.android.setupcompat.util.WizardManagerHelper;
+
 import java.util.List;
 
 /**
@@ -110,7 +110,7 @@
 
     @Override
     public void launchChooseLock(Bundle chooseLockFingerprintExtras) {
-        final boolean isInSetupWizard = !Utils.isDeviceProvisioned(this);
+        final boolean isInSetupWizard = !WizardManagerHelper.isDeviceProvisioned(this);
         Intent intent = isInSetupWizard ? new Intent(this, SetupChooseLockGeneric.class)
                 : new Intent(this, ChooseLockGeneric.class);
         intent.setAction(mNewPasswordAction);
diff --git a/src/com/android/settings/search/SearchFeatureProvider.java b/src/com/android/settings/search/SearchFeatureProvider.java
index 896f6e5..20d4e7c 100644
--- a/src/com/android/settings/search/SearchFeatureProvider.java
+++ b/src/com/android/settings/search/SearchFeatureProvider.java
@@ -34,6 +34,8 @@
 import com.android.settings.overlay.FeatureFactory;
 import com.android.settingslib.search.SearchIndexableResources;
 
+import com.google.android.setupcompat.util.WizardManagerHelper;
+
 /**
  * FeatureProvider for Settings Search
  */
@@ -67,8 +69,9 @@
             return;
         }
 
-        if (!Utils.isDeviceProvisioned(activity) ||
-                !Utils.isPackageEnabled(activity, getSettingsIntelligencePkgName(activity))) {
+        if (!WizardManagerHelper.isDeviceProvisioned(activity)
+                || !Utils.isPackageEnabled(activity, getSettingsIntelligencePkgName(activity))
+                || WizardManagerHelper.isAnySetupWizard(activity.getIntent())) {
             final ViewGroup parent = (ViewGroup) toolbar.getParent();
             if (parent != null) {
                 parent.setVisibility(View.GONE);
diff --git a/src/com/android/settings/search/actionbar/SearchMenuController.java b/src/com/android/settings/search/actionbar/SearchMenuController.java
index 25d0d30..0243c09 100644
--- a/src/com/android/settings/search/actionbar/SearchMenuController.java
+++ b/src/com/android/settings/search/actionbar/SearchMenuController.java
@@ -17,8 +17,8 @@
 package com.android.settings.search.actionbar;
 
 import android.annotation.NonNull;
+import android.app.Activity;
 import android.app.settings.SettingsEnums;
-import android.content.Context;
 import android.content.Intent;
 import android.content.pm.PackageManager;
 import android.os.Bundle;
@@ -37,6 +37,8 @@
 import com.android.settingslib.core.lifecycle.LifecycleObserver;
 import com.android.settingslib.core.lifecycle.events.OnCreateOptionsMenu;
 
+import com.google.android.setupcompat.util.WizardManagerHelper;
+
 public class SearchMenuController implements LifecycleObserver, OnCreateOptionsMenu {
 
     public static final String NEED_SEARCH_ICON_IN_ACTION_BAR = "need_search_icon_in_action_bar";
@@ -61,13 +63,14 @@
 
     @Override
     public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
-        final Context context = mHost.getContext();
-        final String SettingsIntelligencePkgName = context.getString(
+        final Activity activity = mHost.getActivity();
+        final String SettingsIntelligencePkgName = activity.getString(
                 R.string.config_settingsintelligence_package_name);
-        if (!Utils.isDeviceProvisioned(mHost.getContext())) {
+        if (!WizardManagerHelper.isDeviceProvisioned(activity)
+                || WizardManagerHelper.isAnySetupWizard(activity.getIntent())) {
             return;
         }
-        if (!Utils.isPackageEnabled(mHost.getContext(), SettingsIntelligencePkgName)) {
+        if (!Utils.isPackageEnabled(activity, SettingsIntelligencePkgName)) {
             return;
         }
         if (menu == null) {
@@ -83,17 +86,17 @@
         searchItem.setShowAsAction(MenuItem.SHOW_AS_ACTION_ALWAYS);
 
         searchItem.setOnMenuItemClickListener(target -> {
-            final Intent intent = FeatureFactory.getFactory(context)
+            final Intent intent = FeatureFactory.getFactory(activity)
                     .getSearchFeatureProvider()
-                    .buildSearchIntent(context, mPageId);
+                    .buildSearchIntent(activity, mPageId);
 
-            if (context.getPackageManager().queryIntentActivities(intent,
+            if (activity.getPackageManager().queryIntentActivities(intent,
                     PackageManager.MATCH_DEFAULT_ONLY).isEmpty()) {
                 return true;
             }
 
-            FeatureFactory.getFactory(context).getMetricsFeatureProvider()
-                    .action(context, SettingsEnums.ACTION_SEARCH_RESULTS);
+            FeatureFactory.getFactory(activity).getMetricsFeatureProvider()
+                    .action(activity, SettingsEnums.ACTION_SEARCH_RESULTS);
             mHost.startActivityForResult(intent, SearchFeatureProvider.REQUEST_CODE);
             return true;
         });
diff --git a/src/com/android/settings/users/UserSettings.java b/src/com/android/settings/users/UserSettings.java
index 5ad68fe..7a9f026 100644
--- a/src/com/android/settings/users/UserSettings.java
+++ b/src/com/android/settings/users/UserSettings.java
@@ -74,6 +74,8 @@
 import com.android.settingslib.drawable.CircleFramedDrawable;
 import com.android.settingslib.search.SearchIndexable;
 
+import com.google.android.setupcompat.util.WizardManagerHelper;
+
 import java.io.IOException;
 import java.io.InputStream;
 import java.util.ArrayList;
@@ -224,7 +226,7 @@
         super.onCreate(icicle);
         addPreferencesFromResource(R.xml.user_settings);
         final Activity activity = getActivity();
-        if (!Utils.isDeviceProvisioned(activity)) {
+        if (!WizardManagerHelper.isDeviceProvisioned(activity)) {
             activity.finish();
             return;
         }
@@ -977,7 +979,8 @@
 
     private void updateAddUser(Context context) {
         if ((mUserCaps.mCanAddUser || mUserCaps.mDisallowAddUserSetByAdmin)
-                && Utils.isDeviceProvisioned(context) && mUserCaps.mUserSwitcherEnabled) {
+                && WizardManagerHelper.isDeviceProvisioned(context)
+                && mUserCaps.mUserSwitcherEnabled) {
             mAddUser.setVisible(true);
             final boolean moreUsers = mUserManager.canAddMoreUsers();
             mAddUser.setEnabled(moreUsers && !mAddingUser && mUserManager.canSwitchUsers());
