Skip to content

ReaganM02/himuon-gf-klaviyo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Himuon Integration for Klaviyo and Gravity Forms

Gravity Forms + Klaviyo

WordPress add-on that connects Gravity Forms to Klaviyo. It maps form fields to Klaviyo profile attributes, creates/updates profiles, and subscribes them to a chosen Klaviyo list.

Demo

Requirements

  • WordPress 6.1+
  • PHP 7.4+
  • Gravity Forms 2.9+

What it does

  • Adds a Gravity Forms Add-On (feed-based).
  • Lets admins:
    • configure a Klaviyo Private API key
    • validate a Klaviyo List ID
    • map Gravity Forms fields to Klaviyo profile attributes (email, first name, last name)
  • On submission, creates/updates a Klaviyo profile and adds it to the selected list.
  • Tracks success/failure on each entry and provides manual re-sync buttons in the entry sidebar.

Setup

  1. Install and activate Gravity Forms.
  2. Install and activate this plugin.
  3. In WordPress admin, go to Forms -> Settings -> Klaviyo Integration and set your Klaviyo Private API Key.
  4. Edit a form: Settings -> Klaviyo.
  5. Create a feed:
    • Enter the Klaviyo List ID
    • Click Validate List ID
    • Map required fields (email is required)

How sync works

  • On form submission, the add-on:
    1. Builds a profile payload from mapped fields.
    2. Sends it to Klaviyo's profile-import API.
    3. Adds the resulting profile ID to the chosen list.
  • Entry meta is saved to track:
    • list ID
    • profile ID
    • sent time
    • success flag

Manual re-sync

If a sync fails, open the entry in Gravity Forms. The sidebar shows "Klaviyo Feeds" with a Sync button for each active feed.

Data sent to Klaviyo

  • Email (required)
  • Mapped form fields (e.g., first name, last name)
  • A properties.himuon_gf.form_name attribute containing the form title

Project structure

  • himuon-gf-klaviyo.php - plugin bootstrap, activation checks
  • src/Addon.php - Gravity Forms Add-On implementation
  • templates/ - admin UI templates
  • assets/ - admin JS/CSS

Notes

  • Requires the Klaviyo Private API key with List and Profile read/write access.
  • Uses Klaviyo API revision 2025-10-15.

License

GPL-2.0+