Skip to content
Last updated

HubSpot integration

HubSpot is a CRM platform that helps businesses manage contacts, companies, deals, and customer interactions. Integrating HubSpot with Frontegg allows your application to read and write CRM data — including contacts, companies, deals, quotes, and owners — on behalf of your users through OAuth 2.0 authentication.


Prerequisites

  • A HubSpot account with developer access

Connect HubSpot

Step 1: Open the developer portal

Go to developers.hubspot.com and sign in with your HubSpot account.

HubSpot developer portal homepage

Step 2: Go to Legacy Apps

Once signed in, you will be in your HubSpot developer account. In the left sidebar, navigate to DevelopmentLegacy Apps. This page lists all existing applications in your account.

HubSpot Legacy Apps list

Step 3: Create a new app

Click Create legacy app in the top right corner.

In the dialog that appears, select Public (for apps that can be installed by any HubSpot account) and click Next.

HubSpot Create Legacy App dialog

Step 4: Fill in the app name

On the App Info tab, enter a name for your application in the Public app name field (for example, "Frontegg Integration"). This name appears in HubSpot tools when users install your app.

HubSpot app name form

Step 5: Configure auth settings

Click the Auth tab to open the authentication configuration page.

HubSpot Auth settings tab

Step 6: Add redirect URLs

Scroll down to the Redirect URLs section. Enter the following redirect URLs, adding each one separately by typing the URL and clicking + Add redirect URL:

  • https://YOUR_MCP_GATEWAY_URL/integration-callback

HubSpot redirect URLs configuration

Step 7: Add OAuth scopes

Scroll down to the Scopes section and click Add new scope. Select the required scopes from the list:

ScopeDescription
crm.objects.contacts.readRead contact records
crm.objects.contacts.writeCreate and update contact records
crm.objects.companies.readRead company records
crm.objects.companies.writeCreate and update company records
crm.objects.deals.readRead deal records
crm.objects.deals.writeCreate and update deal records
crm.objects.owners.readRead owner (user) records
crm.objects.quotes.readRead quote records
crm.objects.quotes.writeCreate and update quote records
crm.objects.line_items.readRead line item records
crm.objects.line_items.writeCreate and update line item records
crm.schemas.contacts.readRead contact property schemas
crm.schemas.companies.readRead company property schemas
crm.schemas.deals.readRead deal property schemas
crm.schemas.custom.readRead custom object schemas

Minimum required scopes

For basic CRM functionality, you need: crm.objects.contacts.read, crm.objects.companies.read, crm.objects.deals.read.

HubSpot scope selection dialog

After selecting all required scopes, click Update.

HubSpot scopes selected

Step 8: Create the app

Once all required details are set, click Create app at the bottom of the page.

HubSpot Create app button enabled

Step 9: Copy your credentials

After the app is created, the Auth settings page displays your app credentials:

  • Client ID — Your app's unique identifier used to initiate OAuth.
  • Client secret — Click Show to reveal the secret. Used to exchange authorization codes for access tokens.

Copy both values and store them securely.

Keep your credentials secure

Never share or commit your Client secret to version control.

HubSpot app credentials page

Configure the Frontegg portal

Once you have obtained your Client ID and Client secret from the steps above, enter them in the integration configuration page of the Frontegg portal:

  1. Open the Frontegg portal and navigate to [ENVIRONMENT] → Integrations → HubSpot.
  2. Enter the Client ID and Client secret in the corresponding fields.
  3. Select the required scopes.
  4. Click Save.

Additional resources