{"id":531,"date":"2022-10-27T20:24:08","date_gmt":"2022-10-27T20:24:08","guid":{"rendered":"https:\/\/sfplugin.com\/docs\/how-to\/how-to-setup-salesforce-web-to-lead-web-to-contact-web-to-account-or-any-object-with-example\/"},"modified":"2025-01-24T19:49:43","modified_gmt":"2025-01-24T19:49:43","slug":"how-to-setup-salesforce-web-to-lead-web-to-contact-web-to-account-or-any-object-with-example","status":"publish","type":"docs","link":"https:\/\/sfplugin.com\/docs\/how-to\/how-to-setup-salesforce-web-to-lead-web-to-contact-web-to-account-or-any-object-with-example\/","title":{"rendered":"How to Setup Salesforce Web-to-Lead, Web-to-Contact, Web-to-Account or any object (with Example)"},"content":{"rendered":"<p>You can easily setup forms similar to Web-to-Lead for Web-to-Contact or Web-to-Account and other objects used in your Salesforce instance. This post explains how you can set up these forms to send information from WordPress to Salesforce. No coding knowledge needed!<\/p>\n<blockquote><p><a href=\"\/how-to\/connect-wordpress-form-to-salesforce-gravity-forms-wp-forms-ninja-forms-formidable-contact-form-7\/\" title=\"How to connect Gravity form and other plugins to Salesforce no add-ons\" >Here&#8217;s how to connect your current web form, Gravity Form, Contact Form 7 &#8211; cf7 and more without Add-ons (Updated 2025)<\/a><\/p><\/blockquote>\n<p>Using Elementor Pro? you can build the same forms with Elementor as well.<\/p>\n<ul><a target=\"_blank\" href=\"https:\/\/sfplugin.com\/docs\/how-to\/connect-elementor-forms-to-salesforce\/\" rel=\"noopener noreferrer\">How to Connect any Salesforce Object to Elementor Forms in 2025<\/a><\/ul>\n<p>Firstly, we review some of the limitations of the standard Web-to-Lead feature. After that, we show how you can setup Web-to-Lead, Web-to-Contact, Web-to-Account or any Salesforce object. These can be deployed and added to any of your WordPress pages or posts.<\/p>\n<h2>Table of Contents<\/h2>\n<h2><a href=\"#limitations-web-to-lead\">Major Limitations of Web-to-Lead<\/a><\/h2>\n<ol>\n<li><a href=\"#cannot-connect-other-objects\">Cannot connect to other objects<\/a><\/li>\n<li><a href=\"#cannot-create-more-than\">There is limit of 500 leads<\/a><\/li>\n<li><a href=\"#no-email-notifications\">Does not send email notifications<\/a><\/li>\n<li><a href=\"#lookup-field-restriction\">Restrictions on lookup fields<\/a><\/li>\n<li><a href=\"#manage-multiple-forms\">Not easy to manage multiple forms<\/a><\/li>\n<\/ol>\n<h2><a href=\"#integration-sawfish-wordpress\">Setup Salesforce and WordPress integration for\u00a0Web-to-Lead, Web-to-Contact, Web-to-Account forms<\/a><\/h2>\n<p>Here&#8217;s the steps to setup a Web-to-Contact, Web-to-Account or a Web-to-Lead for Salesforce on your WordPress website<\/p>\n<ol>\n<li><a href=\"#install-sawfish\">Install and setup the Sawfish WordPress plugin<\/a><\/li>\n<li><a href=\"#setup-web-to-lead\">Using the integration to setup a Web-to-Lead form (Example) <\/a><\/li>\n<li><a href=\"#setup-web-to-contact-form\">Setup a Web-to-Contact and Web-to-Account form<\/a><\/li>\n<li><a href=\"#setup-email-notification\">Email Notifications for the forms<\/a><\/li>\n<li><a href=\"#publish-form\">Publish your form<\/a><\/li>\n<\/ol>\n<h2><\/h2>\n<h2 id=\"what-is-web-to-lead\">What is Web-to-Lead?<\/h2>\n<p>Salesforce Trailhead has a module on how <a href=\"https:\/\/trailhead.salesforce.com\/content\/learn\/modules\/lead-generation-for-marketers\" target=\"_blank\" rel=\"noopener noreferrer\">Lead Management<\/a> can be used to grow your business. Salesforce Web-to-Lead is an essential feature that gives you the ability to capture Lead information directly from your website. However, it comes with several limitations. The main one being that you can only connect to the Lead object.<\/p>\n<p>We will cover some more of these limitations in this article. Also, we explain how you can easily setup a full integration between Salesforce and your WordPress website that lets you set up Web-to-Contact, Web-to-Account or any custom object forms without these limitations! It is works with both Salesforce Lighting and Classic.<\/p>\n<h2 id=\"limitations-web-to-lead\">Major Limitations of Web-to-Lead<\/h2>\n<h2 id=\"cannot-connect-other-objects\">Cannot connect to other objects.<\/h2>\n<p>Web-to-Lead is a feature designed to collect Lead information only. While there is a similar function for collecting Case information, it cannot be used to Create Contacts, Accounts and other object records.<\/p>\n<h2 id=\"cannot-create-more-than\">There is limit of 500 leads<\/h2>\n<p>\u200b\u200bSalesforce has placed a <a href=\"https:\/\/help.salesforce.com\/s\/articleView?id=sf.customize_leadpreparation.htm&amp;type=5\" target=\"_blank\" rel=\"noopener noreferrer\">restriction of 500 leads per day<\/a> that can be created using Web-to-Lead forms. This is regardless of the number of forms you create using the feature.<\/p>\n<h2 id=\"no-email-notifications\">Does not send email notifications<\/h2>\n<p>Web-to-Lead notifications have to be <a href=\"https:\/\/help.salesforce.com\/s\/articleView?id=000382122&amp;type=1\" target=\"_blank\" rel=\"noopener noreferrer\">set up via a Workflow<\/a>. It doesn\u2019t send an email when a lead is created.<\/p>\n<h2 id=\"lookup-field-restriction\">Restrictions on lookup fields<\/h2>\n<p>Lookup fields cannot be populated via Web-to-Lead forms, <a href=\"https:\/\/ideas.salesforce.com\/s\/idea\/a0B8W00000GdVcSUAV\/autopopulate-value-in-lookup-field-on-webtolead-form?_ga=2.67538325.528681061.1666804312-1310516497.1629217038\" target=\"_blank\" rel=\"noopener noreferrer\">as pointed by a member of the community<\/a>. This is essential if you have a business rule that assigns all Leads to a particular User or Account or any related object record.<\/p>\n<h2 id=\"manage-multiple-forms\">Not easy to manage multiple forms<\/h2>\n<p>Finally, many organizations would want to have multiple lead pages from various landing pages and campaigns. It is not ideal to set up forms from scratch for each of these pages. It is also common to run into a need to update existing forms; managing these edits is a pain.<\/p>\n<h2 id=\"integration-sawfish-wordpress\">Setup Salesforce and WordPress integration for\u00a0Web-to-Lead, Web-to-Contact, Web-to-Account forms<\/h2>\n<p>The first step is to connect Salesforce and WordPress. The Sawfish plugin utilizes the Salesforce API to set up a robust integration between your Salesforce instance and WordPress website. This means you can send and receive information between the two systems &#8211; without the Web-to-Lead limitations!<\/p>\n<h2 id=\"install-sawfish\">Install and setup the plugin<\/h2>\n<p><a href=\"https:\/\/sfplugin.com\/\" target=\"_blank\" rel=\"noopener noreferrer\">Download the plugin from the Sawfish website<\/a> and follow the step-by-step instructions to set up the integration.<\/p>\n<p>The plugin sets up an integration using the Salesforce API, once the connection is active you can show Salesforce records on WordPress and send form information to Salesforce!<\/p>\n<p>Let\u2019s set up a form to capture Lead information. The same steps can be followed for Web-to-Contacts, Web-to-Account and Web-to-any Salesforce object!<\/p>\n<h2 id=\"setup-web-to-lead\">Set up a Web-to-Lead, Web-to-Account and Web-to-Contact form<\/h2>\n<p>We\u2019ll use the <a href=\"https:\/\/wordpress.org\/plugins\/html-forms\/\" target=\"_blank\" rel=\"noopener noreferrer\">HTML forms plugin<\/a> to quickly set up forms for any Salesforce object. Compared to other clunky form plugins it is brilliant, light weighted and loaded with just the essential features.<\/p>\n<h2 id=\"setup-web-to-lead\">How to setup a Web-to-Lead form (Example)<\/h2>\n<p>Click on Add New Form from HTML forms.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-560 alignnone\" src=\"https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Add-New-Salesforce-Web-to-Contact-Form-WordPress.png\" alt=\"\" width=\"210\" height=\"161\" srcset=\"https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Add-New-Salesforce-Web-to-Contact-Form-WordPress.png 364w, https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Add-New-Salesforce-Web-to-Contact-Form-WordPress-300x229.png 300w\" sizes=\"auto, (max-width: 210px) 100vw, 210px\" \/><\/p>\n<p>The interface is easy to use. You can drag the fields on to the forms section and set the values for specific fields.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\" wp-image-562 alignnone\" src=\"https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/HTML-Form-to-insert-Salesforce-Web-to-Lead-record-1024x842.png\" alt=\"\" width=\"459\" height=\"378\" srcset=\"https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/HTML-Form-to-insert-Salesforce-Web-to-Lead-record-1024x842.png 1024w, https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/HTML-Form-to-insert-Salesforce-Web-to-Lead-record-300x247.png 300w, https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/HTML-Form-to-insert-Salesforce-Web-to-Lead-record-768x632.png 768w, https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/HTML-Form-to-insert-Salesforce-Web-to-Lead-record.png 1914w\" sizes=\"auto, (max-width: 459px) 100vw, 459px\" \/><\/p>\n<p>Copy paste short code to the page where you\u2019d like to show the form.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-561 alignnone\" src=\"https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Form-Shortcode-Salesforce-Web-to-Lead-Web-to-Contact-1024x396.png\" alt=\"Form Shortcode Salesforce Web-to-Lead, Web-to-Contact\" width=\"396\" height=\"153\" srcset=\"https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Form-Shortcode-Salesforce-Web-to-Lead-Web-to-Contact-1024x396.png 1024w, https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Form-Shortcode-Salesforce-Web-to-Lead-Web-to-Contact-300x116.png 300w, https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Form-Shortcode-Salesforce-Web-to-Lead-Web-to-Contact-768x297.png 768w, https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Form-Shortcode-Salesforce-Web-to-Lead-Web-to-Contact.png 1086w\" sizes=\"auto, (max-width: 396px) 100vw, 396px\" \/><\/p>\n<p>We need to specify a few additional fields so that it&#8217;s set up to collect Leads. You can use this code below to quickly set up a Lead form.<\/p>\n<p>The <strong>name=&#8221;sf-o&#8221;<\/strong> field sets the object to connect as Lead (value=&#8221;Lead&#8221;). The name=&#8221;sf-form&#8221; sets this as a form to create records. You can use the form to <a href=\"https:\/\/sfplugin.com\/docs\/how-to\/how-to-send-form-information-from-wordpress-to-salesforce\/\" target=\"_blank\" rel=\"noopener noreferrer\">update records<\/a> as well!<\/p>\n<p>Mark fields in sf-Field Name format. Here we have added Names, Email and Phone. You can set say field <strong>LeadSource <\/strong>as <strong>sf-LeadSource<\/strong>.<\/p>\n<p>&lt;input name=&#8221;<strong>sf-LeadSource<\/strong>&#8221; type=&#8221;text&#8221; value=&#8221;Web&#8221; \/&gt;<\/p>\n<p>You can use set values for lookup fields as well! Something that\u2019s not possible with the standard Web-to-Lead form.<\/p>\n<p>&lt;input name=&#8221;<strong>sf-Campaign__c<\/strong>&#8221; type=&#8221;hidden&#8221; value=&#8221;7010K000001hnCRQAH&#8221; \/&gt;<\/p>\n<h2 id=\"setup-web-to-contact-form\">Setup a Web-to-Contact and Web-to-Account form<\/h2>\n<p>Here&#8217;s the code for sending Contact information from WordPress to Salesforce.<\/p>\n<pre lang=\"html\"><input name=\"sf-form\" type=\"hidden\" value=\"create\" \/>\r\n<input name=\"sf-o\" type=\"hidden\" value=\"Contact\" \/>\r\n\r\n<label>First Name<\/label> \r\n<input name=\"sf-FirstName\" type=\"text\" placeholder=\"First Name\" \/>\r\n\r\n<label>Last Name<\/label> \r\n<input name=\"sf-LastName\" required=\"true\" type=\"text\" placeholder=\"Last Name\" \/>\r\n\r\n<label>Email<\/label> \r\n<input name=\"sf-Email\" type=\"text\" placeholder=\"Email\" \/>\r\n\r\n<label>Phone<\/label> \r\n<input name=\"sf-Phone\" type=\"text\" placeholder=\"Phone\" \/>\r\n\r\n<input name=\"sf-AccountId\" type=\"hidden\" value=\"0012800000KKPAPAA9\" \/>\r\n\r\n<input type=\"submit\" value=\"Send\" \/>\r\n<\/pre>\n<p>same can be done for Accounts as well, just change the <strong>sf-o<\/strong> to Account and set the fields.<\/p>\n<pre lang=\"html\"><input name=\"sf-form\" type=\"hidden\" value=\"create\" \/>\r\n<input name=\"sf-o\" type=\"hidden\" value=\"Account\" \/>\r\n\r\n<label>Name<\/label> \r\n<input name=\"sf-Name\" type=\"text\" placeholder=\"Name\" \/>\r\n\r\n<label>Type<\/label> \r\n<input name=\"sf-Type\" type=\"text\" placeholder=\"Type\" \/>\r\n\r\n<label>Phone<\/label> \r\n<input name=\"sf-Phone\" type=\"text\" placeholder=\"Phone\" \/>\r\n\r\n<label>Website<\/label> \r\n<input name=\"sf-Website\" type=\"text\" placeholder=\"Website\" \/>\r\n\r\n<input type=\"submit\" value=\"Send\" \/>\r\n<\/pre>\n<h2 id=\"setup-email-notification\">Setup Email Notifications<\/h2>\n<p>This function will notify you whenever a new Lead or form submission is created.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-559\" src=\"https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Web-to-Contact-Salesforce-Email-Notification-Form-1024x803.png\" alt=\"\" width=\"457\" height=\"358\" srcset=\"https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Web-to-Contact-Salesforce-Email-Notification-Form-1024x803.png 1024w, https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Web-to-Contact-Salesforce-Email-Notification-Form-300x235.png 300w, https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Web-to-Contact-Salesforce-Email-Notification-Form-768x602.png 768w, https:\/\/sfplugin.com\/docs\/wp-content\/uploads\/2022\/10\/Web-to-Contact-Salesforce-Email-Notification-Form.png 1444w\" sizes=\"auto, (max-width: 457px) 100vw, 457px\" \/><\/p>\n<h2 id=\"publish-form\">Publish your form<\/h2>\n<p>Copy the shortcode and paste it onto a WordPress page or post.<\/p>\n<h2 id=\"more-sawfish-features\">What more can the Sawfish plugin do?<\/h2>\n<ul>\n<li><a href=\"https:\/\/sfplugin.com\/docs\/how-to\/how-to-show-salesforce-records-in-wordpress-plugin\/\" target=\"_blank\" rel=\"noopener noreferrer\">Show records in Card, Calendar and Table layouts<\/a><\/li>\n<li><a href=\"https:\/\/sfplugin.com\/docs\/how-to\/make-wordpress-into-a-salesforce-portal\/\" target=\"_blank\" rel=\"noopener noreferrer\">Set up a Portal to login unlimited users!<\/a><\/li>\n<li><a href=\"https:\/\/sfplugin.com\/docs\/how-to\/add-a-volunteer-calendar-from-salesforce-in-wordpress\/\" target=\"_blank\" rel=\"noopener noreferrer\">Set up a Volunteers Signup features for Volunteer4Salesforce<\/a><\/li>\n<\/ul>\n<p>You can check <a href=\"https:\/\/sfplugin.com\/docs\/\" target=\"_blank\" rel=\"noopener noreferrer\">more pages here<\/a>!<\/p>\n","protected":false},"featured_media":0,"parent":148,"menu_order":10,"comment_status":"closed","ping_status":"closed","template":"","doc_tag":[],"class_list":["post-531","docs","type-docs","status-publish","hentry"],"comment_count":0,"_links":{"self":[{"href":"https:\/\/sfplugin.com\/docs\/wp-json\/wp\/v2\/docs\/531","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sfplugin.com\/docs\/wp-json\/wp\/v2\/docs"}],"about":[{"href":"https:\/\/sfplugin.com\/docs\/wp-json\/wp\/v2\/types\/docs"}],"replies":[{"embeddable":true,"href":"https:\/\/sfplugin.com\/docs\/wp-json\/wp\/v2\/comments?post=531"}],"version-history":[{"count":65,"href":"https:\/\/sfplugin.com\/docs\/wp-json\/wp\/v2\/docs\/531\/revisions"}],"predecessor-version":[{"id":1670,"href":"https:\/\/sfplugin.com\/docs\/wp-json\/wp\/v2\/docs\/531\/revisions\/1670"}],"up":[{"embeddable":true,"href":"https:\/\/sfplugin.com\/docs\/wp-json\/wp\/v2\/docs\/148"}],"next":[{"title":"How to Integrate Salesforce and Elementor","link":"https:\/\/sfplugin.com\/docs\/how-to\/how-to-integrate-salesforce-and-elementor\/","href":"https:\/\/sfplugin.com\/docs\/wp-json\/wp\/v2\/docs\/986"}],"prev":[{"title":"Setup a Salesforce Nonprofit Website Integration for Volunteers in 2026","link":"https:\/\/sfplugin.com\/docs\/how-to\/salesforce-nonprofit-wordpress-website-integration-for-volunteers\/","href":"https:\/\/sfplugin.com\/docs\/wp-json\/wp\/v2\/docs\/621"}],"wp:attachment":[{"href":"https:\/\/sfplugin.com\/docs\/wp-json\/wp\/v2\/media?parent=531"}],"wp:term":[{"taxonomy":"doc_tag","embeddable":true,"href":"https:\/\/sfplugin.com\/docs\/wp-json\/wp\/v2\/doc_tag?post=531"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}