diff --git a/core/java/android/service/autofill/Dataset.java b/core/java/android/service/autofill/Dataset.java
index d04ff8e..115894f 100644
--- a/core/java/android/service/autofill/Dataset.java
+++ b/core/java/android/service/autofill/Dataset.java
@@ -115,6 +115,8 @@
  * with the lower case value of the view's text are shown.
  *   <li>All other datasets are hidden.
  * </ol>
+ * <p>Note: If user enters four or more characters, all datasets will be hidden</p>
+ *
  */
 public final class Dataset implements Parcelable {
     /**
diff --git a/services/autofill/java/com/android/server/autofill/ui/FillUi.java b/services/autofill/java/com/android/server/autofill/ui/FillUi.java
index cdd9ef4..0a8fe62 100644
--- a/services/autofill/java/com/android/server/autofill/ui/FillUi.java
+++ b/services/autofill/java/com/android/server/autofill/ui/FillUi.java
@@ -426,12 +426,18 @@
             if (mDestroyed) {
                 return;
             }
+            final int size = mFilterText == null ? 0 : mFilterText.length();
             if (count <= 0) {
                 if (sDebug) {
-                    final int size = mFilterText == null ? 0 : mFilterText.length();
                     Slog.d(TAG, "No dataset matches filter with " + size + " chars");
                 }
                 mCallback.requestHideFillUi();
+            } else if (size > 3) {
+                // Do not show suggestion if user entered four or more characters
+                if (sDebug) {
+                    Slog.d(TAG, "Not showing fill UI because user entered more than 3 characters");
+                }
+                mCallback.requestHideFillUi();
             } else {
                 if (updateContentSize()) {
                     requestShowFillUi();
diff --git a/services/autofill/java/com/android/server/autofill/ui/InlineFillUi.java b/services/autofill/java/com/android/server/autofill/ui/InlineFillUi.java
index ac8d962..24eab0b 100644
--- a/services/autofill/java/com/android/server/autofill/ui/InlineFillUi.java
+++ b/services/autofill/java/com/android/server/autofill/ui/InlineFillUi.java
@@ -216,6 +216,16 @@
             }
             return new InlineSuggestionsResponse(inlineSuggestions);
         }
+
+        // Do not show suggestion if user entered four or more characters
+        if (!TextUtils.isEmpty(mFilterText) && mFilterText.length() > 3) {
+            if (sVerbose) {
+                Slog.v(TAG, "Not showing inline suggestion because user entered more than 3 "
+                        + "characters");
+            }
+            return new InlineSuggestionsResponse(inlineSuggestions);
+        }
+
         for (int i = 0; i < size; i++) {
             final Dataset dataset = mDatasets.get(i);
             final int fieldIndex = dataset.getFieldIds().indexOf(mAutofillId);
