Updating from 25 to 27

There was an upgrade path for your problem. Read here.

You can (after backup your old installation, data, database, …):

a.) use the path on your old maschine
or better:
b.) install the old Debian Bullseye on your new maschine, migrate your old installation on your new maschine and then use the upgrade path
or much better:
c.) maybe you can direct restore Nextcloud 25 on your Debian Bookworm and then use the updater.phar.

b.) is far more expensive but minimizes your risk if my way fails. Do not destroy your data on your old system (a.))

For migration read also backup, restore and updater.phar.