How to Authenticate/Re-authenticate Ahrefs in Google Sheets, Google Data Studio & Microsoft Excel

This guide gives instructions on how to authenticate Ahrefs with Google Sheets, Google Data Studio and Microsoft Excel. 


Quick links to specific sections: 

Google Sheets

Data Studio

Excel

"If everything fails..." 

Data Source Access Requirements:

Before authenticating the connector, please make sure you have gone through the rights and permissions required for this data source. To enable Supermetrics for Ahrefs you must have an Ahrefs paid plan subscription, at least a Lite package. Please see all pricing plans from this guide:

A valid Admin or Owner user role level is required. To learn more, please refer to these guides:

  • A valid Ahrefs account with at least an Admin or Owner user role.

Owner: Can pay, manage subscriptions, add users, change user roles, and change workspace settings.

Admin: Can manage subscription, add users, change user roles, and change workspace settings.


Adding multiple user accounts:

Please note that with this data source it's not possible to add multiple user accounts within the same login. To login with a different user account, you must log out from the previous user account. 


Authenticating with Google Sheets:

To authenticate Ahrefs in Google Sheets, please do the following steps:

1. Open up the Supermetrics sidebar in your Google Sheets. 

2. Select Ahrefs in the sidebar, under data source.

3. An automatic Ahrefs login page will open, click on start.


4. Insert your Ahrefs credentials (email and password) and click on sign in.


5. Click on allow. If you wish to learn more about data security and data privacy, please see this page



6. You have completed all the steps. You can now go back to the sidebar and see your Ahrefs user account under data source. 


*Please note that with this data source it's not possible to add multiple user accounts within the same login. If you wish to login with a different user account, you must log out from the previous user account by clicking on log out all

 

Re-authenticating with Google Sheets:

To re-authenticate Ahrefs in Google Sheets, please go to this guide.


Authenticating with Data Studio:

To authenticate Ahrefs in Google Data Studio, please do the following steps:

1. Click on add data.

2. Search for Ahrefs by Supermetrics and click on it. 

3. Click on authorise. If you wish to learn more about data security and data privacy, please see this page

4. Insert your Ahrefs credentials (email and password) and click on sign in.

5. Click on allow. If you wish to learn more about data security and data privacy, please see this page


6. Select query type and click on next

If you wish to learn more about report types and query limitations, please refer to this guide


7. Insert target URL. Depending on the query type you choose, there will be additional filters to choose.


8. Click on add on the bottom right side to continue. 


9. As a final step, click on add to report.


User accounts with Data Studio


1. Click on the link below to add additional user accounts or to remove old user accounts. If you don't need to add/remove user accounts, you can skip this step.

2. 

*Please note that with this data source it's not possible to add multiple user accounts within the same login. If you wish to login with a different user account, you must log out from the previous user account by clicking on Remove.


To continue with the same user account, click on Ok, let's continue.



Team management with Data Studio


From the link below, you can access your team management page, where you can change assigned users on your licenses, add new team members, etc. For more details, please see Team Management Basics.


Re-authenticating with Data Studio:

To re-authenticate the connector in Data Studio, please go to this guide.


Authenticating with Excel:

To authenticate Ahrefs in Excel, please do the following steps:

1. Click on data and open up the Supermetrics sidebar in Excel.

2. Select Ahrefs in the sidebar under data source.

3. An automatic popup will open, click on start.



4. Insert your Ahrefs credentials (email and password) and click on sign in.


5. Click on allow. If you wish to learn more about data security and data privacy, please see this page


6. You have completed all the steps. You can now go back to the sidebar and select your Ahrefs user account under data source.


*Please note that with this data source it's not possible to add multiple user accounts within the same login. If you wish to login with a different user account, you must log out from the previous user account by clicking on the X right next to the account's name.  

Re-authenticating with Excel:

To re-authenticate the connector in Excel, please go to this guide.

"If everything fails..." 

Common errors:

If you encounter any of the following errors below, please see the guide linked after the error message.

  • Error: "Authentication failed" & "You need to re-authenticate at X and then run the query again.", please see this guide
  • Error: "This was a reauthorization request for user X but logged in as user Y", please see this guide
  • Error: "You're not allowed to run queries with this license #12345. This is because you have not been assigned to the license as a valid user." please see this guide.
  • Error: "This action is not supported when you are signed into multiple accounts". please see this guide.
  • If you no longer see a specific account/page/etc. when logging in, please see this guide
  • If you haven't managed to authenticate you might be affected by an issue at Google account management. For more information, please see this guide.

Forcing a refresh per account data & removing a data source:

To force a refresh per data source, please see this guide.

To force a refresh per data source, please see this guide.

To remove a data source from Google Sheets, please see this guide.

To remove a data source from Data Studio, please see this guide.

To remove a data source from Excel, please see this guide.


Further assistance 

If you followed all the above steps and you still encounter an authentication error, please create a new support request with the details of the issue and we will assist you.

Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.