Dynamic Lead FormsEmbedding

URL Prefill

Fill in answers from the page URL before the visitor starts

Add query parameters to a URL and the form opens with those answers already filled in. Use it for campaign links, emails, and ads where you already know who the visitor is.

https://YOUR_WEBSITE.com/demo?<questionId>_<fieldName>=<value>

Where It Works

Where the form livesPut the parameters on
Embedded with the Surface Tag (inline, popup, slideover, widget)The URL of your page
Surface form link (forms.withsurface.com/s/<formId>)The form link
Your own <iframe> without the Surface TagThe iframe src

On a custom form domain, the Surface Tag needs data-custom-domain set, or the parameters never reach the form.

1. Find the Question ID

Open the form in the builder, select the question, and open the Behavior tab. Copy the Question ID.

Question ID Location

2. Pick the Field Name

The part after the underscore depends on the question type.

Question typeParameterValue
Contact details<questionId>_<field> (see below)Any text
Short text<questionId>_inputAny text
Long text<questionId>_inputAny text
Dropdown<questionId>_selectedOption text, exactly as shown
Multi-select dropdown<questionId>_selectedOption texts, comma separated
Multiple options<questionId>_choicesOption texts, comma separated

Contact Details Fields

FieldField name
First namefirstName
Last namelastName
Full namefullName
EmailemailAddress
Work emailworkEmailAddress
PhonephoneNumber
CompanycompanyName
Job titletitle
WebsitewebsiteUrl
Company sizenumberOfEmployees
Company revenuecompanyRevenue
Street addressstreetAddress
Apt, suiteaptSuiteEtc
Citycity
Statestate
Zip codezipCode
Countrycountry

3. Build the URL

Join parameters with &. One contact details question can take several fields.

https://YOUR_WEBSITE.com/demo?abc123_firstName=Jane&abc123_emailAddress=jane%40acme.com&def456_selected=United%20States

Replace abc123 and def456 with your question IDs.

Rules

  • Option values must match the option text exactly, including case. Values that match nothing are ignored.
  • A comma always separates options, so an option containing a comma cannot be prefilled.
  • URL-encode values: space is %20, @ is %40, + is %2B.
  • An email field that blocks personal emails ignores a personal address from the URL.
  • url, referrer, and cookies are reserved parameter names.
  • Other parameters (utm_*, gclid) are untouched and still attribute the visit.
  • Visitors can edit prefilled answers before submitting.

Not Supported

  • Single choice questions (pick one buttons).
  • Multiple options questions on a Surface form link. They prefill only when embedded with the Surface Tag.

Ready to Get Started?

See it on your own site, or open the app and build the first form.

Need Help?

Setup problems, blocked domains and CRM push failures live in the Help Center.

Feature Requests?

Tell us what is missing. We would rather hear it than guess.

On this page