Last modified: August 25, 2025
Apps on the new developer platform (version 2025.2) are initialized using the HubSpot CLI, via a series of streamlined commands. The app’s configuration (name, authentication type, etc.) and any features are specified using individual configuration files, which are bundled into a project. The steps below walk you through the process of creating a new app using the CLI, uploading the associated project to your HubSpot account, which you can install and test in a developer test account.
This article provides a full setup guide to customize and deploy a new app using the hs project create command.If you’re new to building apps on HubSpot, check out the quickstart guide that will get you up and running with a demo app using the streamlined hs get-started command.

Prerequisites

  • To create an app on the latest version of the developer platform, you’ll need to install the HubSpot CLI and authenticate it with your account using the hs account auth command. Make sure you’re using v7.6.0 of the HubSpot CLI before proceeding. If you’ve already installed the CLI, you can update to the latest version of the CLI by running npm install -g @hubspot/cli@latest.
  • You may want to create a configurable test account so that you can build and test in an isolated environment.

Customize a new project using the CLI

1

Create a new boilerplate project

  • Run the command below in your terminal to create a new project with a boilerplate template to get you started.
hs project create
  • Follow the commands to set up your project. When prompted to select the base contents of your project, select App.
  • Continue to follow the CLI prompts to configure your app details, including:
    • [—distribution]: select whether you plan to distribute your app on the HubSpot App Marketplace or if want to restrict installation to a specific HubSpot accounts.
    • [—auth]: select whether you want to use OAuth for the ability to authenticate multiple accounts, or opt for a static token to limit installation to a specific account.
    • [—features]: select which app features to include, which will create a directory for each feature, along with the respective config files you’ll need to get started. Press spacebar to select a feature, the a key to toggle all features, the i key to invert your current selection, and the enter key to proceed. The following app features are available:
    After selecting your app features, the HubSpot CLI will create a top-level project directory, as well as subdirectories for the app features you chose. Next, you’ll customize the configuration for the app and any of its associated features.
You can add a boilerplate feature to your app at any time by running the hs project add command in the root directory of the project.
2

Configure the newly created project and upload it to your developer account

The projects framework moves app features that were previously configured in the UI or via the API over to source code files, typically defined as <file-name>-hsmeta.json configuration files.App features are then created using a combination of subfolders from the main /src/app directory and other configuration files as needed. Learn more about your app’s project structure and schema options in the app configuration reference documentation.

Configure UIDs and initial app features

Update the UIDs of your app and any features:
  • Change the uid property of the app in the top-level app-hsmeta.json file and give a unique name to represent your new app.
Example app-hsmeta.json
{
  "uid": "new_developer_platform_app",
  "type": "app",
  "config": {
    "description": "An example to demonstrate how to build an app with developer projects.",
    "name": "my first app",
    "distribution": "marketplace",
    "auth": {
      "type": "oauth",
      "redirectUrls": ["http://localhost:3000/oauth-callback"],
      "requiredScopes": [
        "crm.objects.contacts.read",
        "crm.objects.contacts.write"
      ],
      "optionalScopes": [],
      "conditionallyRequiredScopes": []
    },
    "permittedUrls": {
      "fetch": ["https://api.hubapi.com"],
      "iframe": [],
      "img": []
    },
    "support": {
      "supportEmail": "support@example.com",
      "documentationUrl": "https://example.com/docs",
      "supportUrl": "https://example.com/support",
      "supportPhone": "+18005555555"
    }
  }
}
  • For any features you want to include (e.g., app cards), update the UID within any associated *-hsmeta.json configuration files in your project.
Keep in mind that UIDs are used as a unique identifier for all your project’s components and features. Once your app or any of its features has been uploaded with a specific UID, changing it in subsequent deployments will force the platform to recognize it as different from previous builds, which may not be intended.

Set up OAuth (if applicable)

If you plan on distributing your app to multiple accounts (either with a specific set of allowlisted accounts or via the HubSpot app marketplace), you’ll need to set up OAuth for your app by following the steps below. Otherwise, you can skip this step and proceed to upload your project.
  • Add one or more valid redirect URLs to the app-hsmeta.json file based on your local (or another non-production) OAuth server configuration.
  • If you don’t have a backend service set up already, you can get started by using the sample OAuth Node.js example and run it locally. It’s already set up to work with https://localhost:3000/oauth-callback as the redirect URL configured in the boilerplate example code from the hs project create command you ran in the previous step.
Example app-hsmeta.json
{
  "uid": "new_developer_platform_app",
  "type": "app",
  "config": {
    "description": "An example to demonstrate how to build an app with developer projects.",
    "name": "my first app",
    "distribution": "marketplace",
    "auth": {
      "type": "oauth",
      "redirectUrls": ["http://localhost:3000/oauth-callback"],
      "requiredScopes": [
        "crm.objects.contacts.read",
        "crm.objects.contacts.write"
      ],
      "optionalScopes": [],
      "conditionallyRequiredScopes": []
    },
    "permittedUrls": {
      "fetch": ["https://api.hubapi.com"],
      "iframe": [],
      "img": []
    },
    "support": {
      "supportEmail": "support@example.com",
      "documentationUrl": "https://example.com/docs",
      "supportUrl": "https://example.com/support",
      "supportPhone": "+18005555555"
    }
  }
}

Upload your project

After you’ve updated your app and feature schemas, run the hs project upload CLI command to upload your project to your HubSpot account and automatically trigger a new build.If your app is configured to use OAuth authentication, proceed to the next step to retrieve the app’s authentication details. Otherwise, you can proceed to app installation.
3

Add the client ID and client secret of your app to your app

If you configured the authentication type to use oauth, you’ll need to set up your backend OAuth server to use your app’s client ID and secret, which you can find in HubSpot:
  • In the terminal, run hs project open from within your local project directory to open the project details page in HubSpot.
  • Under Project Components, click the name of your app.
Screenshot of the app name shown on the project details page
  • Click the Auth tab.
  • Under Client credentials, copy the Client ID and Client secret from your new app and paste them into the corresponding locations in your OAuth server’s configuration, then restart your OAuth server.
Screenshot showing the client credentials of a developer platform app
Your app is now ready to test with an installed account.
4

Create a developer test account (optional) and install your app

If you don’t already have a test account, you can create one in HubSpot:
  • Navigate to Test accounts in the Development navigation menu, then click Create developer test account. Follow the prompts to create your new test account.
  • In the left sidebar menu, navigate to Projects, click the name of your new project, then click the UID of your app in the component list.
  • On the Auth tab, copy your app’s install link.
  • Use this link to install the app in your developer test account.
  • Open the test account and navigate to the Connected Apps page, where you should see your installed app listed.

Local development and previews

Once you’ve successfully installed the app into the test account, you can run hs project dev to start developing your app locally. When running this command, you’ll see a link to view your project status and source code within your primary developer account as well as a link to access a local development homepage in your test account. This homepage will provide you details about the active local development session, including which components are being developed locally and how you can preview those components to test your changes in real time.
Screenshot showing the local development homepage

Next steps

Check out the documentation for guidance on configuring an app card and creating a settings page for your app.