Erasing and reinstalling the OS is a major operation, do you really need to do this,
why is your mac performing poorly, what are the problems you are experiencing.
If the problems are caused by failing hardware resetting your mac will be no help whatsoever.
It may be possible to sort your mac out by examining any reports and noting things that could be
causing your mac to misbehave, could be as simple as uninstalling software which is not kind to your mac,
or just freeing up space.
First of all make a full back up of your mac.
Download and then run this app, https://binaryfruit.com/drivedx there is a free trial period.
If your mac passes this test then you may want to try running this app, https://etrecheck.com
the free version is fine, this will generate a report on your mac which you can post back here using
the Additional Text button on the toolbar at the bottom of a Reply window here.
No personal information is included in the report.
Do not rely on Apples Recovery Servers to reinstall an OS for you, please make sure you have a means
to restore your mac at your own hands.
The first thing to do is download a copy of the Install macOS High Sierra.app.
Do this by clicking on this link, use your Safari browser.
How to get old versions of macOS - Apple Support
Go to Use Safari to download macOS, click on macOS High Sierra.
This will download the Install macOS High Sierra.app to your Applications folder.
Now create a bootable USB flash drive installer using these instructions.
How to create a bootable installer for macOS – Apple Support (UK)
After creating the bootable USB restart your mac while pressing and holding the option/ alt
key. In two minutes you will see the Boot Manager, select the USB and press Return.
The mac will now boot to the USB, you will see a Utilities panel.
Click on Disk Utility press Continue.
Click View in the menubar and select Show All Devices.
Highlight the Disk (Apple SSD....... or similar) not any of the indented Volumes.
Give the Disk a name.
Format: APFS,
Scheme: GUID Partition Map.
Click Erase.
When Done quit Disk Utility.
Click on Install OS press Continue.
The installation process will start, follow the prompts.
If you have erased and installed macOS High Sierra you can then think about restoring your personal data from
the backup you made earlier. Only restore your personal data from within your Users/<Useraccount> folder.
Do not restore any system or library folders, as this will put the older perhaps buggy system back on.
Do no restore any apps from the backup ,install them press either from the App Store Purchased page or from
the original installer app/ downloads you kept safe for a rainy day.