How to restore a standalone server from a pg_basebackup using the fetch option

I am attempting to make a backup & restore of a production Postgres server (9.6 Windows) for development testing. This server is standalone and does not need to do streaming replication.

I have used

.\pg_basebackup -Ft -Z -D D:\pgbackup\default -P -U postgres -Xf --checkpoint=fast 

I am using -Xf option since the database is quite large and I want to compress it. Using the option -Xs from the standby server is too slow, and using this option on primary server requires the tablespaces to be empty.

After backup the tar files are extracted into base and each tablespace. I’ve created a recovery.conf with single entry

standby_mode = off 

However on starting postgres I get the error

2021-06-17 10:39:27.211 CAT,,,4664,,60cb0a3f.1238,1,,2021-06-17 10:39:27 CAT,,0,FATAL,XX000,"could not connect to the primary server: FATAL:  the database system is starting up 

What is the correct procedure to create a standalone backup?