Stopping the macOS installation may cause file corruption. But since a factory reset will erase all data on your Mac and reinstall a new operating system, the corruption part isn't really a concern. Just make sure you back up your Mac before taking any action.
It's advisable to reinstall macOS from Internet Recovery Mode before erasing your Mac. To do it, ensure you have a stable internet connection and follow the steps below:
- Press Command + Q to exit the installation window and then shut down your Mac. Or simply hold down the power button to force shut down your Mac.
- Hit the power button, then immediately press and hold Option + Command + R until the spinning globe shows up.
- Select "Reinstall macOS" and click Continue.
- Follow the onscreen instructions to install macOS.
If the installation still hangs for a long time, you can erase your startup disk and retry the installation again.