Keep holding the button until the (computer and cable icon) appears. Open Finder (Mac) or iTunes (Windows).

Method 1: Use Apple’s "Erase iPhone" Feature (iOS 15.2 and Later)