For files you need to follow these steps:
If the site has used a database (it is necessary for such popular CMS as WordPress, Joomla, or OpenCart), then you also need to do the following:
Save a backup copy of the database for the desired date
Connect the database in the configuration file
In case you are seeing "Error establishing a database connection" or a similar error, refer to this article: How to fix "Error establishing a database connection"?
After the restoration, your website will be brought back to the state it was at the moment of backup creation. All the changes that were done after the backup date will be reverted