Creating Salesforce WordPress Integration Using Object Sync

There are a variety of ways to send form submissions on your WordPress website to Salesforce via a web to lead integration. But what if you want to go further, and build other connections between your WordPress website and your Salesforce data?

In the past, you would need to hire a specialist developer to build a custom system for you, connecting your website to Salesforce via their proprietary API. However, the Object Sync for Salesforce plugin simplifies a lot of this by creating a flexible system that allows you to build connections between WordPress metadata and Salesforce objects right in your WordPress dashboard. With this plugin, it’s entirely possible to sync specific data to, from, and/or between your website and Salesforce without writing a single line of code. And did we mention that it’s free?

Step 1: Authorize the Plugin

Once you’ve installed and activated the plugin on your website, you’ll need to log into Salesforce and create a new Application that will provide the authorization needed to send data back and forth. This can sound a little confusing, but it’s really easy. The plugin documentation provides detailed instructions on creating the application in Salesforce, selecting the correct settings, and then entering the appropriate fields into the plugin settings on your website to authorize the connection. You can find them under the “Salesforce” heading on this documentation page.

After successfully creating your Salesforce application and authorizing the connection, you can start building and mapping connections between your Salesforce objects and WordPress data. The first step is to navigate to the Fieldmaps tab in the Object Sync for Salesforce plugin settings. Click “Add New” to create a new connection, and on the following screen you’ll be asked to configure a few settings.

Step 2: Choose Your Salesforce and WordPress Objects

First, you’ll want to label your connection so that you’ll remember what it’s doing. Once you’ve entered a label, you’ll want to choose the WordPress object to connect to. This can be a post type, taxonomy, or user. If you’ve registered any custom post types or taxonomies, you will be able to connect to those as well, but you may need to ensure that you have at least one post or term set up before the option appears in the dropdown.

Once you’ve selected the WordPress object for the website side of the connection, you’ll want to select the corresponding Salesforce object to link to. Once you’ve selected both object types, the last thing to choose is which date field triggers Salesforce to send data to WordPress. You may want to trigger an update every time the a specific object is updated in Salesforce (choose “Last Modified Date”), or maybe even any time the specific object is viewed, regardless of updates (choose “Last Viewed Date”). Some Salesforce objects with their own date fields may have options for other date triggers as well.

In our example, we’re connecting the Salesforce Contacts table to our WordPress users, so that when new contacts are added in Salesforce, their data will be added to a WordPress user account.

Object Sync for Salesforce Settings

Step 3: Connect Specific Fields Between WordPress and Salesforce

After you’ve finished with those settings, you can start connecting the individual fields on each side of the connection. Depending on the settings we’ll select later, you can either send field data from the website to Salesforce, from Salesforce to the website, or sync the fields so that if the data is modified on one side, it will be updated to match on the other.

To set up a new field map, click the “Add Field Mapping” button. You’ll notice that a new row is added to the table above the button.

In the new row, you can use the WordPress Field dropdown to select data from your WordPress object and then link it to a corresponding Salesforce data field using the Salesforce Field dropdown. The options for both dropdowns will be populated based on the WordPress and Salesforce Object selections you made earlier. If you’re trying to map a Salesforce field to a meta field on the WordPress side but aren’t seeing the meta key in the dropdown, make sure that at least one post has a value for that specific meta key. If there are no existing metadata entries, the plugin won’t be able to recognize it as a mappable field.

Once you’ve mapped your two fields, you can choose the Direction radio button that corresponds with how you want the data sent. The data can travel in a single direction (ie only from WordPress to Salesforce, or vice versa), or you can choose to sync the data, so that if one side of the connection is changed, the other side will be updated to match as well.

Repeat this process to add as many connections between fields as you’d like. Once you’ve set up all your field maps, you’ll want to choose a single field to check the “Prematch” checkbox. This will be the field that identifies existing versus new entries in your data. If a match is found for your “Prematch” field on either side, then the corresponding record will be updated. If no match is found, than a new record will be created.

Object Sync for Salesforce Settings

Step 4: Configure Which Actions Trigger an Update

With all of your field maps created, the hard work is done! All that’s left is to select a few more settings that determine which actions will trigger your connection. Under the “Action Triggers” setting, you will find checkboxes corresponding to actions on both the WordPress and Salesforce sides that will let you fine tune when data is sent between the two. Depending on how you want to manage the data, you may choose one, several, or all of the options.

The last three settings are optional, and all include descriptions that will let you determine whether or not you want to use them. Once you’ve finished making your selections, you can click the “Add Fieldmap” button at the bottom of the screen to save your connection.

Object Sync for Salesforce Settings

Depending on which settings you chose for your field map directions and triggers, you can run a test to make sure your connection is working. Updates on the WordPress side should trigger the connection to fire immediately (again, depending on your settings). However, Salesforce updates don’t directly trigger the connection to fire; the plugin performs a check at a set interval to monitor changes to Salesforce, and if those changes meet the criteria for you connection, then the connection will fire accordingly. You can adjust how often the plugin checks Salesforce in the Scheduling tab.

And that’s it! While that may not have seemed like the simplest process to you, the reality is that before this plugin existed, building a similar connection would have been a very expensive process limited only to developers capable of working with the Salesforce API. The Object Sync for Salesforce plugin goes beyond a single-use solution and provides an entire framework for building robust connections between these two platforms, and enables creating Salesforce WordPress integrations for a much larger portion of the public.

Still, it may be a bit naïve for us to say that this plugin makes building these connections “easy.” As a group of web developers, a lot of the knowledge we take for granted isn’t necessarily a given for all WordPress website owners. If you’re having trouble with any part of this process, don’t be afraid to reach out to us; we’re always ready and waiting to help!

Leave a Comment


Work With Us

We've been building websites for over twenty years, and have learned a thing or two about how to make web projects go smoothly.

What Our Clients Say

Watermelon Web Works, LLC place picture
4.7
Based on 19 reviews
powered by Google
OMS Anita profile picture
OMS Anita
22:20 29 Nov 24
Watermelon Web Works has been incredible to work with. They are patient, understanding, and quick to answer any questions (or emergencies) you might have. After switching over to them to help re-vamp our online retail store, we hired them to build our wholesale website as well. I can't recommend them enough - Thank you team!
Garrett Lister profile picture
Garrett Lister
19:55 10 Jul 24
Jared and the watermelon team were great - they quickly interpreted our website needs and designed a wonderful site. The project management site worked great to keep track of project.
N B profile picture
N B
21:23 14 Nov 23
My previous web developer who I was very happy with retired and I was pretty sad about it because it seems now days it is hard to hire a web developer close by with a good set of skills who is interested in helping small business at reasonable prices. Then I found Watermelon and I have been very happy. They are responsive, are able to solve problems, and work at reasonable prices.
Dark Star Magick profile picture
Dark Star Magick
18:05 03 May 23
We hired Watermelon to help us with our website. They were very thorough and took the time to explain in layman's terms what they were doing and how we could improve SEO and site functionality. We will definitely be back for future website needs!
Astoria Column profile picture
Astoria Column
18:42 24 Apr 23
Great work and amazing service! We're a non-profit, and our priorities are always focused on maintaining the Astoria Column. We had a website built by someone else a few years ago, but without regular updating and maintenance, sections of our site were no longer functional. Joanna and the rest of the team came in and had everything working within a week and it's been smooth sailing since then!
Ben Harris profile picture
Ben Harris
19:25 26 Aug 19
Watermelon has been a fantastic web development partner. Through every phase of our project they have always been 100% responsive to our requests and have always provided highly knowledgeable, creative, prompt, and personable team members to work with. As a financial institution we’re always concerned about the security and maintenance or our website and Watermelon has always provided the appropriate resources in order to meet and/or exceed our compliance and security requirements. We would surely refer them to any business associates looking for a qualified WordPress web designer in the future. – Denali Federal Credit Union
Mohr IP Law Attorneys profile picture
Mohr IP Law Attorneys
00:33 11 Apr 19
Watermelon Web Works did a great job creating a custom shopping cart page for our firm. Gavynn in particular was especially helpful and responsive. We appreciated the upfront costs and the technical competency of Watermelon Web Works and would not hesitate to work with the people there again.
Kim Markle profile picture
Kim Markle
23:36 08 Feb 19
Our company has been working with the Watermelon team for more than 10 years to help build and grow our website and customer portal. They are not only extremely talented and responsive, but are continuously looking for ways for us to enhance our current website. They are consistent, provide excellent customer service and really know what they are doing. Highly recommend!
Rick Brodner profile picture
Rick Brodner
23:23 12 May 17
I cannot say enough good things about Watermelon. They are terrific communicators, highly competent coders, and really, really nice people. They were instrumental in helping us to assemble a very usable, easily maintainable website for our organization. They' have demonstrated great flexibility in accommodating our evolving needs. They have been highly responsive to any technical issues, typically resolving them in less than 4 hours. Watermelon Web Works will make your organization better, and your CFO/Treasurer will be happy when they see the bill - what more can you ask for?
CLOSE