Migration of files from one server to another

I need to migrate the files from the old server to the new one. How do I do? Is it possible to migrate through folders? Or just file by file?

Documentation how to migrate ownCloud to a different server is available at:

https://doc.owncloud.org/server/latest/admin_manual/maintenance/migrating.html