Location of login/autostart apps setting file in macOS

Solution 1:

Part of the list is stored in ~/Library/Preferences/loginwindow.plist under the LoginHook key.

Also you'll find a set of LaunchAgents stored in this folder:

~/Library/LaunchAgents/

Each of the files in there detail a program that is started when your user account logs in.

There's also a similar list in /Library/LaunchAgents and /System/Library/LaunchAgents that are run when any user logs in, so they're not specific to your user.

In earlier versions of macOS it was also usual to place startup items in /Library/StartupItems and /System/Library/StartupItems. But they're usually not in use anymore.