Payroll error message: authentication failure

This article explains the steps to take if you've received an error message telling you there is a problem with your submission when trying to file payroll in FreeAgent.

If HMRC does not recognise the Government Gateway credentials that you have entered, you’ll receive the error message below when trying to submit payroll to HMRC.


There can be a few other reasons for this error message. If you have full (level 8) access to your FreeAgent account, you can follow the steps below to identify and resolve the error.

1. Check that the PAYE and Accounts Office reference numbers are correct

Select 'Settings' from the drop-down menu in the top-right corner and then select 'Company Details'.


Make sure that the ‘PAYE Reference’ and ‘Accounts Office reference’ numbers are correct and match the details in your business tax account.

If either of these reference numbers are incorrect, update them with the correct numbers and select ‘Save Changes’. Find out more about how to update your business's details.


2. Check whether you’ve previously filed payroll using the same Government Gateway credentials

If your accountant has previously filed payroll on your behalf using the credentials that you’re entering into FreeAgent, you may need to register for a new Government Gateway ID (HMRC online account) to file the payroll yourself.

3. Check that you can log in to your HMRC online account using the Government Gateway credentials

Navigate to HMRC’s website to check if you can log in to your HMRC online account using the same Government Gateway credentials that you’re entering into FreeAgent. If you’re unable to log in, please see the following HMRC guidance.

4. Check that PAYE has been enabled as a service

If you can log in to your HMRC online account, make sure that PAYE has been enabled as a service. If it has, it should look similar to the image below.


If PAYE hasn’t been enabled as a service, you’ll need to select ‘get online access to a tax, duty or scheme’ and follow the steps provided to add it. Please note that if you do need to do this, HMRC will send an activation code out in the post which can take up to 10 days to arrive. Once you’ve successfully enabled online filing, you’ll see a notification advising of return deadlines.

enable payroll as a service in business tax account.png

If you haven’t filed payroll yourself before, for example if your accountant was doing this for you previously, you may need to log in to your HMRC online account and authorise PAYE as a service.

5. Check that you’re entering your Government Gateway credentials manually

When submitting payroll through FreeAgent, make sure that your Government Gateway credentials are being entered manually and not being auto-filled by your browser.

If any of your details are being auto-filled, you should delete the auto-filled information and enter your Government Gateway ID and password manually instead, just as you would enter it to access your HMRC online account.

In the majority of cases, the authentication failure error message is caused by PAYE not being enabled as a service on the HMRC online account, the credentials in FreeAgent being auto-filled or not being the same credentials used to access the HMRC online account.

If you continue to receive the error message after completing the troubleshooting steps above, please check with HMRC directly. As the error message has been sent from their system, they will need to investigate.

Did you find this article useful?