> ## Documentation Index
> Fetch the complete documentation index at: https://www.plain.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# HubSpot Service Hub

> Import HubSpot Service Hub ticket history into Plain with a script built on the API.

Bringing your HubSpot Service Hub ticket history into Plain takes a short script built on the Plain API. Your team keeps every past ticket, searchable alongside live threads, from the day you switch. This page covers how Service Hub's data maps onto Plain's and the decisions to make before you run it.

This page is about moving your support history into Plain. To sync company and contact context onto live threads, see the [HubSpot integration](/docs/product/integrations/hubspot).

## What gets imported

* **Contacts → Customers**

* **Tickets → Threads**

  * You choose which pipeline stages land as **Done** and which stay **Todo**

  * The emails and notes on the ticket are carried over. Notes appear as internal comments in Plain

* **Ticket properties you choose → Labels**

* **Original timestamps**: every thread and every message keeps the date it had in HubSpot, so your history stays in order

* **A link back to the original ticket**, so anyone reading the thread in Plain can still find it in HubSpot

CSAT ratings and custom properties on tickets are not imported. See [Migrating from another tool](https://help.plain.com/article/migration) for the full picture of what you'll rebuild in Plain.

Importing history doesn't trigger [SLAs](/docs/product/platform/slas), [auto-responses](/docs/product/platform/auto-responses), or [workflows](/docs/product/workflows), so nothing goes out to your customers and no SLA clocks start on old tickets.

## Mapping service hub onto Plain

Ticket pipelines and stages are set up differently in every HubSpot account, so plan this against your own:

* **Pipelines and stages.** Plain has three status groups: **Todo**, **Snoozed**, and **Done**, rather than stages you define. Decide which of your stages land as Done and which stay Todo. If the stage matters for reporting, add it as a [label](/docs/product/platform/labels) so you keep it.

* **Where the conversation lives.** A ticket's history sits in the activities associated with it: emails and notes. Decide which of those your team reads back, and import those. Anything written for users should come in as an internal comment in Plain.

* **Ticket IDs.** Use the HubSpot ticket ID as each thread's external reference. That's what makes the import safe to re-run.

* **Companies.** Plain sets a customer's [Company](/docs/product/platform/companies) automatically from their email domain. If the companies in HubSpot don't line up with domains, create a [Tenant](/docs/product/platform/tenants) per company instead and attach customers to it.

* **Categories, sources, and priority.** Plain threads carry a priority and labels rather than a set of custom properties. Pick the ones your team filters on and bring those across as labels.

* **Owners.** Decide which ticket owners map to the users you've already invited to Plain, and what to do with anyone who has left.

## Running the import

<Snippet file="shared/ticket-importer-walkthrough.mdx" />

If you'd like a hand scoping the script or a review before you run it at full volume, email [help@plain.com](mailto:help@plain.com).
