## Ahrefs integration Integrating Ahrefs with Frontegg lets your application read backlink, keyword, rank-tracking, site-audit, and brand-radar data on behalf of a connected Ahrefs user through the [Ahrefs API v3](https://docs.ahrefs.com/api). Authentication is OAuth 2.0 Authorization Code with PKCE against the Ahrefs Connect program, with credentials issued by Ahrefs after your integration application is approved. Prerequisites - An [Ahrefs](https://ahrefs.com/) account that will own the integration. - An approved [Ahrefs Connect](https://docs.ahrefs.com/docs/ahrefs-connect/introduction) application. Production access requires an Ahrefs Enterprise plan; development and testing are free. - A publicly available product with an existing user base. Ahrefs does not approve integrations that directly compete with or replicate Ahrefs functionality. ### Apply to Ahrefs Connect #### Step 1: Review the Ahrefs Connect program Open the [Ahrefs Connect introduction](https://docs.ahrefs.com/docs/ahrefs-connect/introduction) and read the program overview. Ahrefs Connect is the only supported integration path for the Ahrefs API v3 — the legacy API v2 program was retired on November 1, 2025. From the introduction page, follow the **How to apply** link. ![Ahrefs Connect introduction page](/assets/ahrefs-1.42f7dc1cf991c7d8c1c3e738ba86f55a35121d75f64151b1ad404ced764bf7f6.1ce25488.png) #### Step 2: Open the application form On the **How to apply** page, click the **application form** link. Ahrefs hosts the submission form on HubSpot Forms and uses it to qualify integration partners before issuing developer credentials. ![Ahrefs Connect How to apply page with the application form link highlighted](/assets/ahrefs-2.910aba85ad9b16398ec6bc47bba9e1865b4c80b0cbc8347c0b636dc5a2bfa685.1ce25488.png) #### Step 3: Submit the application Complete every required field on the form: First name, Last name, Email, Country, Company name, Industry, Website URL, a short description of your product, and how you plan to use Ahrefs data. Ahrefs replies within two business days with next steps. Approval grants access to the **Ahrefs Connect** developer section in your Ahrefs account. ![Ahrefs Connect application form](/assets/ahrefs-3.6c5bad746068fcf75716935ba7aa6c572830c9153cf9b1e20448741d1441e14d.1ce25488.png) Development is free, production requires Enterprise Once your application is approved, you can build and test the integration in **Inactive** status against your account at no cost — test OAuth flows and free API requests do not consume units. Switching the app to **Active** for production traffic requires an Ahrefs Enterprise subscription. ### Create the OAuth application #### Step 4: Open the Applications page Once Ahrefs has approved your application and enabled the Ahrefs Connect developer section on your account, sign in at [app.ahrefs.com](https://app.ahrefs.com/) and open **Account settings → Applications**. Approved developer accounts see a **create your own** action that opens the OAuth app management screen. On a non-approved account, the same page only lists third-party apps the user has authorized. ![Ahrefs Account settings Applications page](/assets/ahrefs-4.b8cefb90e2303b3a5c31037d934b73bdb172843c0e268b73f3e6b74c877c0d91.1ce25488.png) #### Step 5: Register a new app On the Ahrefs Connect app creation screen, enter an **App name** (for example, `Frontegg Integration`), a short description, and your product website. Ahrefs creates the app in **Inactive** status — this is the state you use throughout development to test the OAuth flow and make free API requests. #### Step 6: Configure the redirect URL In the app settings, locate the **Redirect URIs** field and enter your Frontegg redirect URL: - `https://YOUR_MCP_GATEWAY_URL/integration-callback` Replace `YOUR_MCP_GATEWAY_URL` with the MCP Gateway URL from the Frontegg portal **Settings → Basic configuration** page. Ahrefs supports separate staging and production redirect URIs — register the same Frontegg callback in both fields, or only the staging field while your app is **Inactive**. #### Step 7: Copy the Client ID and Client Secret The app overview shows the **Client ID** and **Client Secret** Ahrefs has issued for your integration. Keep both values handy — you will paste them into the Frontegg portal in the next section. The Client Secret is shown only on this screen, so store it somewhere safe before leaving the page. ### Authorized scope Ahrefs Connect issues a single OAuth scope that grants access to every Ahrefs API v3 endpoint your subscription tier supports: | Scope | Description | | --- | --- | | `apiv3-integration-apps` | Access to all Ahrefs API v3 endpoints — Site Explorer, Keywords Explorer, Site Audit, Rank Tracker, Brand Radar, Social Media, batch analysis, subscription info, and management endpoints. | Single scope, no refresh token Ahrefs Connect uses one scope (`apiv3-integration-apps`) and does not issue refresh tokens. Access tokens are valid for one year — after that, the user must re-authorize the integration. ### Configure the Frontegg portal Once you have your **Client ID** and **Client Secret** from Ahrefs, enter them in the Frontegg portal: 1. Open the **Frontegg portal** and navigate to [ENVIRONMENT] → Integrations → Ahrefs. 2. Enter the **Client ID** and **Client Secret** in the corresponding fields. 3. Select the `apiv3-integration-apps` scope. 4. Click **Save**. When a user authorizes the integration, Ahrefs prompts them to sign in and grant your app access to their Ahrefs data. Keep your credentials secure Never share or commit your Client Secret to version control. ### Additional resources - [Ahrefs Connect introduction](https://docs.ahrefs.com/docs/ahrefs-connect/introduction) - [Ahrefs Connect OAuth guide](https://docs.ahrefs.com/docs/ahrefs-connect/developers/oauth-guide) - [Ahrefs API v3 reference](https://docs.ahrefs.com/api) - [How to apply for Ahrefs Connect](https://docs.ahrefs.com/en/ahrefs-connect/docs/how-to-apply) - [How to get your Redirect URL](/agen-for-work/connectors/redirect-url)