# PostHog + Salesforce integration and analysis

Connect PostHog and Salesforce to Hendrik. Test whether a PostHog journey or flagged release change aligns with Salesforce lead and opportunity movement.

## The question this stack can answer

Did product activity turn into Salesforce leads and opportunities?

## What Hendrik reads from each source

- **PostHog:** Events, sessions, releases, and feature flags show whether the product or checkout journey changed.
- **Salesforce:** Leads, opportunities, stages, and campaign membership show whether paid leads become qualified opportunities.

## What you need to connect

- Use one explicit 28-day comparison window, time zone, market, and legal-entity scope before comparing values.
- Connected PostHog project with the relevant event definition and capture coverage.
- Connected Salesforce org with agreed lead, opportunity, and stage definitions.
- Keep provider-specific definitions visible and use an identity or product mapping only where it is established for this workspace.

## Important limits

- Captured events depend on instrumentation and coverage; they do not automatically identify a payment, order, or campaign.
- CRM campaign and opportunity records require an established identity relationship before attribution claims.

## Illustrative example

### PostHog + Salesforce review

Previous: 1–28 January. Current: 29 January–25 February. Both periods contain 28 days. Monetary values use USD and all timestamps use UTC. The example compares acquisition measures with CRM deal progression. A submitted lead and a qualified deal are different events, with different reporting dates. The selected website event is a lead form submission.

*About this example: Synthetic data · illustrative analysis · Hendrik only acts with the permissions you give it.*

- lead_submitted events · selected form (count, 28 days) (PostHog): 230 → 250
- qualified opportunities created (count, 28 days) (Salesforce): 28 → 24

### What Hendrik checks

- **Event and release context:** Check PostHog event definition, instrumentation coverage, feature-flag exposure, annotations, and session scope before interpreting a journey change.
- **Opportunity and campaign definition:** Check Salesforce record type, stage history, campaign membership, and identity coverage before using opportunity movement.
- **Explain the divergence:** PostHog: lead_submitted events · selected form (count, 28 days) changed from 230 to 250. Salesforce: qualified opportunities created (count, 28 days) changed from 28 to 24. Compare the timing and definitions before attributing one change to the other.

### What Hendrik sees

PostHog lead_submitted events rose. Salesforce qualified opportunities created fell.

### What to do next

Review the product or measurement change before modifying acquisition; reassess after the relevant events and stages are stable.

**Limit:** A PostHog person is not automatically a Salesforce lead or opportunity.

## Provider documentation

- [PostHog documentation](https://posthog.com/docs)
- [Salesforce documentation](https://help.salesforce.com/s/articleView?id=sf.reports.htm)

## Start with this stack

[Create a workspace and connect PostHog + Salesforce](https://app.withhendrik.com/auth?mode=sign-up&acquisition_channel=marketing&return_to=%2Fonboarding%2Factivation&cta_location=integration_markdown&landing_page_id=combination-posthog-salesforce&combination=posthog-salesforce)
