This guide will walk you through how to authenticate or reauthenticate Ahrefs with Google Sheets, Data Studio, and Excel, as well as data warehouse destinations like Google Cloud Storage, BigQuery, and the Supermetrics API.
Before you begin
To connect Supermetrics to Ahrefs, you need:
- An Ahrefs paid plan subscription with the Lite package or more. Learn more about all pricing plans in Ahrefs’ documentation.
- An Admin or Owner user role level. To learn how to add member roles and access levels, and how to add a new user to your account.
Multiple user accounts
It's not possible to add multiple user accounts in the same login for Ahrefs. To log in with a different user account, you need to log out from all other Ahrefs accounts in Supermetrics.
Target URL
For the field "target URL" we support HTTP, HTTPS, and WWW.
For Excel users
If your team uses Supermetrics for Excel, you’ll see different options for managing and sharing data source connections in that destination. Learn more.
Instructions
- Open a new Google Sheets file.
- Navigate to Extensions → Supermetrics → Launch to open the Supermetrics sidebar.
- Click Create query
- Under Data source, select Ahrefs.
- Click Start.
- Enter your email address and password, and click Sign in.
- Click Allow.
- Navigate to Report configuration.
- Under Query types, select the query type.
- Under Target URL, insert the target URL.
When you're ready, learn how to create your first Supermetrics query with Ahrefs.
- Open the Supermetrics data source gallery.
- Navigate to Ahrefs and click Try.
- Click Authorize to authorize Supermetrics in Data Studio.
- If you're authenticating the data source for the first time, log in with the Google Account you use with Supermetrics. Click Allow.
- Click Authorize.
- Enter your email address and password, and click Sign in.
- Click Allow.
Navigate to Report configuration.
Under Query types, select the query type and click Next.
Under Target URL, insert the target URL.
- Click Connect on the top right-hand side.
- Click Create report.
- Click Add to report to complete the authentication steps.
When you're ready, learn how to create your first Supermetrics query with Ahrefs.
Add or remove a user account in Data Studio
- Click the edit icon next to the data source's name in the Data Studio sidebar.
- At the top left of the connection pane, click Edit connection.
- Scroll down to Parameters.
- Browse team, account, and license management options in the section beginning "To add more/manage accounts..."
Before you can authenticate the data source in Excel, you need to install the Supermetrics add-in.
- Open an Excel file.
- Click Data → Show Supermetrics.
- Under Data source, select Ahrefs.
- Choose to make this connection shared or private.
- Click Start.
- Enter your email address and password, and click Sign in.
- Click Allow.
- Navigate to Report configuration.
- Under Query types, select the query type.
- Under Target URL, insert the target URL.
When you're ready, learn how to create your first Supermetrics query with Ahrefs.
Explore our guides to set up data transfers to various destinations.
- BigQuery
- Data warehouses and cloud storage (Amazon S3, Google Cloud Storage, Snowflake, Azure Storage, or Azure Synapse)
- The Supermetrics API
Reauthenticate the data source
Troubleshooting
- If you encounter an authentication error such as “authentication failed”, “you need to reauthenticate” or similar, see this guide.
- If you encounter a permission error such as “user permission denied” or similar, follow this guide.