diff --git a/Lib/ensurepip/__init__.py b/Lib/ensurepip/__init__.py
index b291e9afb189746e693de7867ebaf9588dad8459..88ddc63128f5b5b0219c854df670026ff880b67f 100644
--- a/Lib/ensurepip/__init__.py
+++ b/Lib/ensurepip/__init__.py
@@ -29,7 +29,12 @@ def _run_pip(args, additional_paths=None):
 sys.argv[1:] = {args}
 runpy.run_module("pip", run_name="__main__", alter_sys=True)
 """
-    return subprocess.run([sys.executable, "-c", code], check=True).returncode
+
+    cmd = [sys.executable, '-c', code]
+    if sys.flags.isolated:
+        # run code in isolated mode if currently running isolated
+        cmd.insert(1, '-I')
+    return subprocess.run(cmd, check=True).returncode
 
 
 def version():
diff --git a/Misc/NEWS.d/next/Library/2022-01-03-15-07-06.bpo-46197.Z0djv6.rst b/Misc/NEWS.d/next/Library/2022-01-03-15-07-06.bpo-46197.Z0djv6.rst
new file mode 100644
index 0000000000000000000000000000000000000000..7a3b2d59dfaf42a3d2c633963981d0adc933ebd6
--- /dev/null
+++ b/Misc/NEWS.d/next/Library/2022-01-03-15-07-06.bpo-46197.Z0djv6.rst
@@ -0,0 +1 @@
+Fix :mod:`ensurepip` environment isolation for subprocess running ``pip``.