If you just purchased a new device that includes Office 365, Microsoft recommends installing Office before upgrading to Windows 10.
Upgrading to Windows 10 on new devices that include Office 365
If you are facing issues, the initial troubleshooting steps involve uninstalling the recent version of Office and again downloading and installing Office 365 on a PC or simply downloading and installing Office 365 in the first place. Later, while upgrading to Windows 10, choosing the option ‘Keep personal files, apps and Windows settings’ because if accidentally, you choose the option ‘Keep personal files only’, the option to install Office 365 will be erased or gone. If you chose the option ‘Keep personal files only’ to erase all files except personal files, you will need to contact Microsoft Support to get all the complete information essential for installing Office. The problem arises when you have received Office as part of the Home Use Program (HUP), Here, you might need to reinstall Office. You can reinstall Office at any time by going to your Order History. If you purchased a Backup DVD or Backup USB Flash Drive, you can use these tools to re-install the software. You can only re-download or buy additional products if the Software Assurance agreement still runs valid, says Microsoft. Users having the version of Office 365 installed as part of the Volume Licensing Academic Program (VLAP), should sign into the store, look for the place where you ordered your Microsoft Office Professional Plus, go to your Accounts > Orders to find your product key. Use this product key to upgrade to Windows 10 on new devices that include Office 365.