I have a lingering question. For Hybrid Salesforce Apps, why do we need the 'com.salesforce' cordova plugin? We are able to fetch the Salesforce data using the ForceJS library as it is? :)

2 Answers 2


The Mobile SDK is more than just database functionality. It gives you access to offline storage, camera, advanced gestures, notifications, device contact and calendars, and so on. You'll want to read more in Native, HTML5, or Hybrid.

Can you access the camera with ForceJS? How about device notifications? Can you access the native contacts and calendars? Mind you, if all you need is literally Salesforce access, feel free to use ForceJS. If you want anything more complicated than that, like a fully functional application, you'll need more than just Salesforce connectivity, which is where the Mobile SDK comes in play; there's no need to import a half-dozen libraries when you can just import the Mobile SDK and be done with it.

  • hi @sfdcfox . Exactly. I thought the various cordova plugins - camera, notifications, contacts, calender, etc. - would take care of that. So you're saying that few cordova plugins are already part of the Mobile SDK? Is there a list of these in-built components? I could find the following mention in the link you shared: "Built-in components - The camera, address book, geolocation, and other features native to the device can be seamlessly integrated into mobile apps. Another important built-in components is encrypted storage, but more about that later. " Commented Jun 15, 2017 at 12:17
  • @KanavKhurana My point is that the Mobile SDK gives you everything you need to get started. It includes Cordova, Force.com REST API and authentication, as well as SmartStore (encrypted offline storage) and SmartSync (automatically push/pull data when connected to the Internet). Yes, you could go out and get Cordova and ForceJS, but you'd still be missing some features that Mobile SDK offers. And nobody's telling you that you have to use Mobile SDK, it's your choice.
    – sfdcfox
    Commented Jun 15, 2017 at 13:10

There's a few things that you get from the Salesforce SDK, over-and-above what you'd get with just using the forcejs. The big things, in my opinion, are the support of the SmartStore (the encrypted local SQLite DB) and the authentication management. I say this as security is hard, and I'd not advise doing this yourself when there's a team already building it, and it's the same as used in SF1.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .