Skip to content

What’s the Difference Between HubDB and a Custom Object?

Which approach is the best solution for your business needs: using HubDB or creating custom objects? What makes each of these features helpful? Whether you’re a small or mid-sized business, not every system will fit your needs or structure your data in a way that allows you to manage or utilize it efficiently.

Using custom objects allows you to create your own objects to store information and represent customized data you can organize to fit those needs. Using HubDB, on the other hand, is a great way to kick-start managing your business data.

Now, let’s dive in and learn more about the difference between the two, including which supports certain functionalities, so that you can make the best choice for your data source and your specific needs. The topics we’ll explore are:

  • What is HubDB?
  • What are custom objects?
  • When is it best to use HubDB vs custom objects?
  • Conclusion

What is HubDB?

HubDB is a relational database that allows you to store your business data in tables that consist of columns and rows. This database is a ready-to-use approach that allows you to customize your data easily within a familiar spreadsheet-like format.

What’s different about HubDB as compared to some other relational databases is that it integrates natively with the HubSpot platform. This enables you to access HubDB data points via the HubdDB API and displays your data within HubSpot. HubDB is also compatible with HubL, HubSpot’s markdown language, to pull data to use and render it within the CMS as well as to leverage a serverless function for data abstraction. 

Note: HubDB is available via the HubSpot CMS Hub for Professional or Enterprise subscriptions. It’s also available with Marketing Hub Enterprise.

What are Custom Objects?

HubSpot’s custom objects are similar to the standard HubSpot CRM objects you might be familiar with: contacts, companies, deals, tickets, etc. The custom object is a way for you to create an object that represents your data based on your business needs. 

You can use the custom objects API, the HubSpot CLI, or even the UI with a Private App to create your object with a customizable schema, properties, and associations with your other objects to represent your business data. 

Note: Custom objects are available via Enterprise subscriptions. 

When is it best to use HubDB or Custom Objects?

Below we’ll identify use cases and explain which data source approach is best and why.

  • Resource Gallery

Use HubDB

Why?

HubDB lets you dynamically generate content on websites or different pages that allow you to manage your data across multiple areas. This functionality is great for resource libraries, product catalogs, calendars, and other resources you wish to display with your data. 

If you’re already using HubDB and need to display your data using one of the display approaches listed above, it’s simple to do so from the rows of the data tables within the database. HubDB is also a great choice if you don’t need to associate the data within your tables with any CRM data and you meet the technical limits for HubDB.

Here are some real-world examples:

hubdb 1

The collage above includes examples from some of HubSpot’s Solution Partners who utilize HubDB for clients. 

  1. In this example, HubDB is being used to generate information for classes, locations, pricing, etc. for the website pages.
  2. Here, HubDB is being used for a resource gallery displaying the client, Pressboard’s executions based on the publisher, topic, and advertiser, allowing a content manager to easily customize the page.
  3. This Solution Partner built several HubDBs to centralize management of branch locations and loan officer information for this particular client.

Image sources: 1 - SafeSplash,  2 - Pressboard, and 3 - Castle & Cooke Mortgage, LLC

  • Reporting Data

Use custom objects

Why?

Custom objects can be used to create custom object reports so that you can analyze and understand your data better. These reports are based on your custom object records and their properties for your website and business data.

You can define a single-object report or multiple-object custom reports using HubSpot’s reporting tools. Depending on your needs, you can extract these reports, create a list, or display them on a dashboard.

hubdb 2

As you can see in the image above, you can choose which report you’d like to create, and then you are prompted to select the custom object you'd like to create a report for - it’s that easy.

  • Set Workflow Enrollments

Use custom objects

Why?

With custom objects, you can create a workflow for your records and then enroll them into automated actions for your business processes to improve efficiency.

Here are some of the functionalities you can utilize with workflows for your custom objects:

         Object-base workflows

You can utilize the object-based workflows for your custom object by creating a workflow from scratch. 

hubdb 3

The image above highlights a custom object, “Summer Camp,” as an option for an object-based workflow.

         Set enrollment triggers

Enrollment triggers allow you to set triggers for your workflows that you can enroll automatically for your custom object records whenever they meet the criteria you specified. You can utilize a custom object’s properties within the object-based workflows or use standard associated objects in your triggers.

hubdb 4

The image above shows how you can set a trigger for your custom object workflow. 

         Add actions

Once you’ve created your workflow for your custom object and set your enrollment triggers, then you can apply actions to it. Actions behave like functions applied to the workflows. These are executed to initiate an action, such as creating a record, sending an email, or creating a task. There are multiple actions you can enable for your workflow, depending on your HubSpot subscription.

hubdb 5

Once the enrollment is defined, you can apply the action, like the example identified in the image above.

  • Create Associations or Use Association Labels for Complex Relationships

Use custom objects

Why?

When needing to associate an object with other CRM objects (contacts, companies, deals, tickets, etc.), you can create and apply an association with or without a label. 

Labels come in handy when you need to associate records to specify a relationship between associated standard objects. You can use primary labels or create custom association labels to define your object and record relationships. However, we should note that labels are always encouraged and should be used even if an object only has one association. Using labels defines the relationships between objects and eliminates any sort of confusion.

hubdb 6

In the example above, we are creating an association label for a custom object within the HubSpot UI. Once you create this label, you will be able to view it within your custom object record. You can also update or remove these labels and apply them to associated records.

As for a custom object record, the example below shows how to create one and associate it with your custom object within the HubSpot UI:hubdb 7

When creating associations for custom objects without a label, it’s important to note that HubSpot automatically associates the custom object with emails, notes, meetings, calls, tasks, and conversation objects. 

If you want to associate with a different object than the ones listed above, you can do this through a schema request by identifying the custom object by its objectTypeId and associated objects you wish to define:

// Example of associatedObjects array in JSON

"associatedObjects": [

"CONTACT",

"COMPANY",

"9-2478"

]

HubSpot allows you a limit of 50,000 associations per object type, which allows you some freedom when using custom objects with associations. 

In other words, custom objects have a one-to-many relationship with objects and can associate with both standard and custom objects. You can learn more about creating/updating associations for your custom object, here.

  • Authentication

        Authenticated - use custom objects

Why?

Custom objects are particularly useful when it comes to private data and protecting your customers. You can use OAuth or access tokens with HubSpot private apps to create, read or update your custom objects when making API calls.

Note: You can display custom objects without authentication by using HubL within the HubSpot CMS.

        Unauthenticated - use HubDB

Why?

For public data HubDB is a great data source choice because you can create a public API to access the data from the database. Otherwise, you can disable this option and only allow data to be viewed in your app or with authenticated APIs.

hubdb 8

You can toggle the public API access once you’ve created your first table with HubDB on the manage settings page, as in the image above.

Conclusion

It’s not a matter of which data source is better, it’s a matter of which supports your business needs best. Hopefully, this post helps you determine the best approach for those needs. If you have any questions or concerns, please feel free to reach out to us and we can help you determine the best solution.