By using the AES encryption algorithm in XTS mode with a 128-bit key length, APFS encryption is strong disk encryption to protect your drive and secure your data. As a great way to realize full disk encryption, APFS encryption is secure enough.
As one of the four APFS formats that macOS 10.13 and above offers, APFS encryption functions the same as the original APFS format but allows you to encrypt the volume in XTS mode with a 128-bit key length. This encryption algorithm Apple used, AES, is so far the best global standard currently in use and is authorized by the US government.
With APFS encrypted enabled on your drive, your files are protected using a password. It's a variation of APFS that makes sure your files cannot be accessed when connected to another Mac or using some third-party software. Without the correct password, anyone who wants to access your data will be rejected.
Moreover, Apple keeps a good reputation in terms of providing encryption to Mac customers since the 1990s.
Therefore, when formatting your startup drive, adding new volumes, or backing up with Time Machine, you should select APFS (Encrypted) or APFS (Case-sensitive, Encrypted) if you have sensitive or private data saved on your Mac.
This will ensure that the additional password is required to open the encrypted volumes even when your Mac is already logged in. By doing this, you may stop third-party apps from accessing your disk without your permission.