Setup Guide


What This Guide Covers

This guide walks you through the one-time setup required in Salesforce and Klaviyo before the integration can go live. Follow each section in order — skipping steps will cause the integration to fail.

By the end of this setup, the integration will:

  • Sync Contacts and Account data from Salesforce to Klaviyo
  • Send Case events (Created, Updated, Closed, Escalated) to Klaviyo
  • Keep email and SMS consent in sync between both platforms
  • Write Klaviyo email/SMS engagement data back to Salesforce Contact Activity Tasks

Important: All steps in this guide must be performed by a Salesforce System Administrator. Do not proceed without admin access.


Section 1 — Before You Start

Confirm you have everything below before touching any settings.

  • You have System Administrator access in Salesforce
  • You have Account Owner or Full Access in Klaviyo
  • You know your Klaviyo Account ID (Klaviyo → Settings → Account Details)
  • No other Klaviyo account is already connected to this Salesforce account

Note: Salesforce only supports one connected Klaviyo account at a time. Check Klaviyo → Integrations before proceeding.


Section 2 — Set Up Custom Fields in Salesforce

The integration reads and writes specific fields on the Contact object. You need to enable one standard field and create several custom ones.

2.1 Enable Email Opt-Out Field Visibility

HasOptedOutOfEmail is a standard Salesforce field. It just needs to be visible to the System Administrator profile.

  1. Go to Setup → Object Manager → Contact
  2. Click Fields & Relationships
  3. Search for HasOptedOutOfEmail and open it
  4. Click Set Field-Level Security
  5. Check the Visible box for System Administrator and click Save

2.2 Create the SMS Opt In Field

This is a new custom checkbox field you need to create. If already have this field in your sandbox then make sure the name is same.

  1. Go to Setup → Object Manager → Contact
  2. Click Fields & Relationships → New
  3. Select Checkbox as the Field Type and click Next
  4. Fill in the field details:
    • Field Label: SMS Opt In
    • Field API Name: SMS_Opt_In (Salesforce will add __c automatically)
  5. Click Next → Next → Save
  6. Set Field-Level Security the same way as step 4 to 5 above in 2.1 — make it Visible for System Administrator

Important: The API name must be exactly SMS_Opt_In. Any variation will break the consent sync.

2.3 (Optional) Enable Field History Tracking

This step isn't required, but it allows you to see a history of changes to consent fields on the Contact record.

  1. Go to Setup → Object Manager → Contact
  2. Click Fields & Relationships → Set History Tracking
  3. Check the box for Enable Contact History
  4. Check the boxes for Email Opt Out, SMS_Opt_In__c and Email_Opt_In__c (if it exists in your org)
  5. Click Save

Section 3 — Create Workflow Rules

Workflow Rules push data from Salesforce to the integration in real time. You need to create two: one for Case events and one for Contact consent changes.

3.1 Case Events Webhook

This rule fires whenever a Case is created or its Status, Priority, or Escalation changes.

  1. Go to Setup → Process Automation → Workflow Rules

  2. Click New Rule

  3. Select Continue with Workflow Rules

  4. Select Object type: Case and click Next

  5. Set the Rule Name to: Klaviyo Webhook Case Events Rule

  6. Set Evaluation Criteria to: created, and every time it's edited

  7. Set Rule Criteria to: Formula evaluates to true

  8. Paste the following formula into the text box:

    OR(
      ISNEW(),
      ISCHANGED(Status),
      ISCHANGED(Priority),
      ISCHANGED(IsEscalated)
    )
    
  9. Click Check Syntax to confirm there are no errors, if any error occurs please contact Solvative support team for help at support@solvative.com.

  10. Click Save / Next

  11. Under Specify Workflow Actions, click Add Actions → New Outbound Message

  12. Fill in the outbound message details:

    • Name: Klaviyo Case Events Webhook
    • Unique Name: Klaviyo_Case_Events_Webhook
    • Endpoint URL: provided by Solvative
    • User to Send As: your admin username
  13. Under Case fields to send, select all of the following: CaseNumber, ClosedDate, ContactEmail, ContactId, ContactPhone, CreatedDate, Id, IsClosed, IsDeleted, IsEscalated, LastModifiedDate, Origin, OwnerId, Priority, Status, Subject, Type

  14. Click Save

  15. Click Done

  16. Activate the workflow rule by clicking the Activate button. The button only appears after you save the rule. If you don't see it, make sure you've completed all the previous steps correctly and saved the rule.

  17. Finish setting up the workflow rule.

3.2 Consent Events Webhook

This is a new workflow rule you need to create. It listens for changes to a Contact's email and SMS consent status and sends those changes to the integration in real time.

  1. Go to Setup → Process Automation → Workflow Rules

  2. Click New Rule

  3. Select Continue with Workflow Rules

  4. Select Object type: Contact and click Next

  5. Set the Rule Name to: Klaviyo Contact Consent Events Rule

  6. Set Evaluation Criteria to: created, and every time it's edited

  7. Set Rule Criteria to: Formula evaluates to true

  8. Paste the following formula into the text box:

    AND(
      NOT(ISBLANK(Email)),
      OR(
        AND(ISCHANGED(HasOptedOutOfEmail), HasOptedOutOfEmail=True),
        AND(ISCHANGED(SMS_Opt_In__c), SMS_Opt_In__c=false)
      )
    )
    
  9. Click Check Syntax to confirm there are no errors, if any error occurs please contact Solvative support team for help at support@solvative.com.

  10. Click Save / Next

  11. Under Specify Workflow Actions, click Add Actions → New Outbound Message

  12. Fill in the outbound message details:

    • Name: Klaviyo Contact Consent Events Webhook
    • Unique Name: Klaviyo_Contact_Consent_Events_Webhook
    • Endpoint URL: provided by Solvative
    • User to Send As: your admin username
  13. Under Contact fields to send, select: Email, HasOptedOutOfEmail, Id, Phone, SMS_Opt_In__c, Email_Opt_In__c (only if this field exists in your org)

  14. Click Save

  15. Click Done

  16. Activate the workflow rule by clicking the Activate button. The button only appears after you save the rule. If you don't see it, make sure you've completed all the previous steps correctly and saved the rule.

  17. Finish setting up the workflow rule.

Note: Endpoint URLs and secret tokens for both workflow rules will be provided by Solvative. Don't save the rules until you have those values.


Section 4 — Klaviyo Account Check

Before connecting Klaviyo in the integration UI, confirm the following in your Klaviyo account.

  1. Log in as Account Owner or a user with Full Access
  2. Go to Klaviyo → Integrations and confirm no Salesforce org is already connected
  3. Go to Settings → Account Details and copy your Account ID
  4. When the OAuth dialog appears during setup, approve all requested scopes. The integration needs: profiles, events, subscriptions, and metrics access

Important: Do not delete the webhook endpoint that gets created automatically in Klaviyo during setup. Deleting it will break real-time consent and event sync.


Section 5 — Connect the Integration

Once Sections 1–4 are done, you're ready to activate the integration.

  1. Open the integration app at the URL provided by Solvative
  2. Sign in — or accept your invite email if it's your first login. Invite links expire after 7 days. Contact Solvative if yours has expired.
  3. Click Connect Salesforce:
    • It will redirect you to Salesforce login page
    • Login with your salesforce credentials for the account you want to connect.
    • Approve the OAuth authorization in Salesforce
  4. Click Connect Klaviyo and approve all requested scopes
  5. Check the dashboard — both platforms should show a green connected status
  6. Provide Organization Mapping Id:
    • Fill the Organization Mapping Id correctly. This mapping ID becomes a middle segment on every Klaviyo profile custom property synced from this Salesforce org - making it easy to identify which org the data came from.
    • This ID cannot be changed after setup. Renaming it later would break existing Klaviyo segments and flows that reference these properties.
    • Once confirmed and saved you cannot modify it.
  7. (Optional) Trigger a Historical Backfill to sync existing Contacts and Cases into Klaviyo

Section 6 — How Consent Works

A few rules you should be aware of before the integration goes live:

  • If a Contact opts out in either Salesforce or Klaviyo, the opt-out automatically syncs to the other platform
  • Opt-outs are processed immediately — there is no delay
  • The system will never automatically re-subscribe a Contact. Opt-ins must come from an explicit user action
  • Every consent change is logged in an audit trail that cannot be edited or deleted
  • If both platforms receive a consent change at the same time, the most recent one (by timestamp) wins

Important: Never manually override an opt-out in either system without documented proof of re-consent from the customer.


Section 7 — Troubleshooting

Case events not appearing in Klaviyo

Open the Case Events Workflow Rule in Salesforce. Confirm it shows as Active. Test by editing a Case record and checking if the outbound message fires in Setup → Outbound Messages.

Consent changes not syncing

Confirm the Consent Events Workflow Rule is Active. Double-check that the SMS_Opt_In__c API name in the formula exactly matches the field you created in Section 2.2.

Outbound Message delivery failures

Confirm the endpoint URL and secret token in both workflow rules match the values Solvative provided. Endpoint URLs are environment-specific.


Need Help?

Contact the Solvative project team for any setup or activation issues:

Email: support@solvative.com

Web: www.solvative.com

For Klaviyo-specific questions, refer to help.klaviyo.com.

© 2026 Solvative. All rights reserved.