Ideas for better Web to Lead forms
We use web-to-lead forms pretty extensively for our Salesforce clients, because it is so much less expensive for them than integrating with the API. We’ve found that WTL can work not just for ordinary leads, but also for simple event registration, volunteer signup, pledges, and many types of "applications" for service or grants. Leads don’t have to be just people - they can bring in organization, donation, grant, or service information as well.
For example, we worked with a group that matches teen interns to other nonprofits that need interns. The organizations that want interns apply for services on a web-to-lead form; the teen applicants sign up on another. The first type of lead gets converted into an account, a contacts, and an internship "opportunity," while the intern applicants stay as leads until they are either matched to an internship (via contact roles) or rejected and deleted.
This is just one example of how web-to-lead has allowed us to set up simple website integration relatively quickly.
The more you use web-to-lead, however, the less you’ll like the HTML form that Salesforce provides you. We edit the form pretty extensively, for several reasons:
- To arrange and align form fields in a table and apply styles
- To format phone numbers and other values as they are entered
- To provide validation, making certain fields required and helping to avoid spam
- To set hidden values, such as Lead Source or Record Type, that we don’t want to show on the form
- To create or modify a picklist for values, such as Campaign
The first thing I do for web to lead is format the form in a table - two columns, with the labels at left and the fields at right. Then I add styles for labels and fields to the stylesheet. For examples, take a look at forms for Teens in Public Service, Communities Connect Network, and Arts Corps. To see the form’s HTML, view the source code for the page and search for WebToLead.
I will offer other a few other examples of web-to-lead techniques in subsequent posts.

Hi,
We want to do subordinate web to leads which don’t create duplicate lead records.
What I mean is that we want people to fill in basic contact info and sign up for our various interest segments (which are check boxes on our web to lead) but then when they check one or more of “volunteer”. “donate” or “become a member” we want a dependent set of questions to open up for each of these three categories AND a workflow to be generated to the the appropriate individual who handles each of these three categories (volunteers, donors and members). SF customer service told us we needed to customize something. Can we do this ourselves?
Thanks!
What we’ve done is to create separate forms on the site for each of these. The forms share a lot of fields, but each has its own “extra” fields. Each form also has a hidden field that sets lead source (”Web”, “Web - Volunteer Form”, “Web - Member Form”). If you prefer, you could use a single form, but to show and hide dependent fields you would need to write some javascript code.
For the workflow, you set up a lead assignment rule in Salesforce (Setup | Customize | Leads | Assignment Rules). It will assign the web leads to the appropriate person based on the lead source setting.
Hope that helps!
Hi Evan,
Thanks for your helpful post. I would love to know your tips on setting hidden values for Lead Record Type.
Thanks!