Hybrid or Native Mobile App Development: Six Key Considerations:
There has been an ongoing fierce debate, with legitimate pros and cons on either side, as to whether mobile app developers should go native or use a hybrid approach that can accommodate the many different mobile platforms they want to target. Analyst and consulting firm Gartner predicts that more than 50 percent of mobile apps deployed by 2016 will be hybrid. There are several factors to consider when deciding a native vs. hybrid approach, but the most important are related to time to market and development costs.
Considerations key to ROI
A native app is specifically designed to run optimally on a device’s operating system. The hybrid approach combines the portability of the emerging standard HTML5 Web apps with a native container that facilitates access to native device features and thus supports multiple mobile devices.
Based on our experience, the following six considerations are key factors in achieving the anticipated return on investment from developing a mobile app.
Development speed and cost
Hybrid apps are faster to develop. Only a portion of native code has to be re-written for different kinds of devices. The vast majority of development goes into the Web component, which is used across all devices, reducing the time it takes to build the app (and thus the development cost). These are Web apps built into a native mobile container or framework.
This essentially means that they take advantage of the cross-compatibility of Web technologies such as HTML5, CSS, and JavaScript and use the native component to leverage device-specific features such as hardware sensors or the camera.
Building a hybrid mobile application requires maintaining a single code base for the different platforms. Native apps require specific developments for each platform, which increases costs and duration.
Required knowledge
Because hybrid apps are based on Web technologies it is easier to find developers to build them and maintain them. Globally, it is difficult in today’s heated mobile app development market to find developers experienced with iOS and Android. Due to the Web’s historical reality, the great majority of developers come with strong knowledge of Web technologies. That history also is true for other mobile platforms like BlackBerry and Windows 8.
Hybrid apps are a good choice for certain types of requirements. Productivity apps are the most common applications built using HTML5 (54 percent), followed by utility (38 percent).
However, HTML5 alone is not a silver bullet. There are other considerations besides development speed and cost that are usually not part of the decision process when choosing the technology to develop mobile apps with. They include user experience, data persistence, immature tooling and cross-platform support.
User experience
Hybrid apps are not executed natively; the HTML5 and JavaScript portion of the app is rendered and executed by the platform’s Web engine, which adds another layer between the user and the app. This can make things slower to the point where users can, irritatingly, perceive the slowness.
Another drawback is when there is a need for animations or special user interface (UI) treatments, like spinners or custom UIs that require elements to move around the screen. HTML5 is lacking in this area. In fact, this is one of the reasons LinkedIn dropped HTML5 and went native for its mobile app.
The look and feel of the platform is also a factor. One of the benefits of hybrid apps is that developers only have to build once; this is also true for the UI, meaning that the app will look the same across all platforms. Some users expect the apps to look like the other apps they already have. There are some common elements and guidelines that are expected from an app on a specific platform, which cannot be met by hybrid apps.
Data persistence
Data storage plays an important role with mobile apps. It is used to store user preferences and app data that will enable offline use of the application. Hybrid apps use HTML5 storage mechanisms, which are usually restricted to a few megabytes depending on the platform support and implementation of the HTML5 standard. Data-intensive mobile apps are not suitable for a hybrid approach, as there can be significant investment in the effort to make it work successfully.
Immature tooling
The tools to develop hybrid apps are not mature enough to allow developers to fine-tune their code or even help them solve problems that may affect final end users. Tools such as debuggers, memory profilers, and code analysis are still immature for HTML5 and JavaScript in the mobile environment.
Cross-platform support
The majority of a hybrid app is built using Web technologies. However, native code is used to allow the app to access the wider functionality of the device and produce a more refined user experience. If the app requires specialized functionality commonly found in today’s popular apps (such as push notifications where a portion of the code needs to be developed in native code), or when accessing phone contacts, JavaScript needs to check for the platform it is running on.
Although this forces developers to maintain different code bases for the native portions, it is not that bad if compared to the extensive development effort required to maintain a completely different code base per platform. Where it gets ugly is when the HTML5, CSS or JavaScript implementation on the platform behaves differently between platforms. This is the case for functionality related to local storage for data persistence, or even CSS rules for styling.
As far as user interfaces are concerned, most people very likely won’t notice a huge difference from a native app, particularly if there isn’t a significant interactive component in the app.
The debate likely will continue regarding the superiority of native mobile app development over a hybrid approach while the staggering growth of mobile app development and deployment continues in parallel. Apple’s app store boasts over 900,000 apps; Android plays catch-up at 750,000. How will the continued release of apps on both platforms affect the native vs. hybrid debate? And, will the relatively small number of Windows Phone apps (less than 150,000) factor in? Time will tell.
Co-published with Erick Vargas, a software architect with 10+ years of experience in software development including leading mobile hybrid development efforts and assessments.