Technical reference // inspect the rule

HubSpot Prefill Testing Guide

A reference guide for validating query-param, cookie, and literal field mappings before live use.

Separate mapping from submission

Prefill changes what appears in a form. Submission creates or updates data in another system. Test those jobs separately so a display problem is not confused with a payload or permission problem.

Build a mapping register

Record one row for every value the workflow uses:

  • source type: query parameter, cookie, storage, user input, or literal
  • source key
  • destination field’s internal name
  • whether the field is visible, hidden, or required
  • allowed values and fallback behavior
  • owner and last validation date

Use a controlled test set

Create test cases for a complete URL, a missing parameter, an invalid value, an existing cookie, a returning visitor, and a blank optional field. Use synthetic data and forms you are authorized to test.

Check the browser result

Confirm the expected fields populate, user-entered values are not overwritten, unknown parameters are ignored, and sensitive values do not appear in URLs or browser storage.

Protect live submission

Any action that looks up private portal data or submits a record needs an owned, authenticated server-side boundary. Do not place private app credentials in browser code. Preserve the final payload, response, timestamp, and test-case identifier so failures can be reproduced.

Release checklist

  • mapping register reviewed by the workflow owner
  • consent and data-handling requirements confirmed
  • test cases pass in a non-production or controlled form
  • error and retry behavior documented
  • rollback path identified
  • production monitoring owner assigned
Related topic hubs
Related tools