Hi there, ekremcoaccountan. Error 5020 is a security block that occurs when your user profile lacks the necessary "clearance" to perform a payroll or pension action.
To ensure you are the Primary Admin, navigate to the Gear icon > Manage users > Payroll Users. If you are a standard user trying to access a restricted function, this error will trigger.
If you already have admin rights, resolve potential session errors by refreshing your browser, logging out and back in, or using an incognito window on a supported browser, as these work best with QuickBooks.
If your permissions are correct but the error persists, check for sync conflicts:
If you've closed the books and have the status Close the books for the period you're trying to create a payroll journal, you won't be able to create one. If so, turn off the status and run the payroll again.
Navigate to Account and Settings > Advanced > Other preferences. Ensure that Warn when a duplicate journal number is used is switched to On. If this is off, QuickBooks may silently fail to create journals.
If the issue persists, create a "test" journal entry for 0.01 to any account. Ensure this entry uses a unique, never-before-used transaction number in the top right corner. Once saved, try running your payroll again, then delete the test entry.
If you have additional questions, feel free to comment below.