Skip to main content

Native versus cross-platform frameworks to develop accessible apps

It's important to consider accessibility when developing an app. Over 1 billion people in the world have a disability. And 50% of all people use accessibility features on their mobile devices.

A question we are often asked is: "Which framework should I choose to develop an accessible app?"

In this article, we are comparing the pros and cons of Android, iOS, Flutter, React Native and Xamarin. And we added Web equivalents. A conclusion is drawn at the end.

1. Orientation

Apps should support multiple orientations (portrait and landscape) to ensure users can hold devices in their preferred way.

Screenshot of an app in landscape mode, the layout has changed to two columnsScreenshot of an app in landscape mode, the layout has changed to two columns
FrameworkFeatureProsCons
Androidandroid:screenOrientationAll orientations supported by default
iOSUISupportedInterfaceOrientations'Upside Down' disabled by default
FluttersetPreferredOrientationsFlexible
React Nativeexpo-screen-orientation or nativeFlexible
XamarinDevice Orientation or nativeFlexible
Web@media queryExtensive

2. Text scaling

Apps should support text scaling, to ensure users can read text in the font size they need.

Screenshot of an app with increased font size, none of the text is truncatedScreenshot of an app with increased font size, none of the text is truncated
FrameworkFeatureProsCons
AndroidScale-independent Pixels (sp)Scales automatically
iOSUIFontMetricsWrite scaling implementation
FlutterfontSizeScales automatically
React NativefontSizeScales automatically
XamarinSetEnableAccessibilityScalingForNamedFontSizesWrite scaling implementation
Web(r)em unit / Browser zoomScales automatically

3. Contrast

Apps should have sufficient contrast, to ensure users can read text and distinguish interface elements.

Screenshot of an app, text colors are picked using a color picker, the contrast ratio is 4,77:1Screenshot of an app, text colors are picked using a color picker, the contrast ratio is 4,77:1
FrameworkFeatureProsCons
AndroidColor
iOSColorBuilt-in high contrast support
FlutterColor
React NativeColor
XamarinColor
Web<color>

4. Name

Apps should provide an accessible name for interactive elements, to ensure users of assistive technologies can identify them.

Screenshot of an app with Voice Control enabled, numbers and labels are indicated by tooltipsScreenshot of an app with Voice Control enabled, numbers and labels are indicated by tooltips
FrameworkFeatureProsCons
AndroidcontentDescriptionFlexible
iOSaccessibilityLabelFlexible
FluttersemanticsLabelFlexible
React NativeaccessibilityLabelFlexible
XamarinAutomationProperties.NameFlexible
Webaria-labelFlexible

5. Role

Apps should provide an accessible role for elements, to ensure users of assistive technologies know their intent.

Screenshot of an app showing that the role of elements has been marked for assistive technologiesScreenshot of an app showing that the role of elements has been marked for assistive technologies
FrameworkFeatureProsCons
AndroidsetRoleDescription or setClassNameCustom roles
iOSaccessibilityTraitsNo custom roles
FlutterSemantics → roleNo custom roles
React NativeaccessibilityRoleNo custom roles
XamarinSemanticEffectsetDescription3rd party library, uses contentDescription
Webrole / aria-roledescriptionCustom roles

6. Value

Apps should provide an accessible value for elements, to ensure users of assistive technologies know their current value.

Screenshot of an app showing that a selected item has been marked as selected for assistive technologiesScreenshot of an app showing that a selected item has been marked as selected for assistive technologies
FrameworkFeatureProsCons
AndroidAccessibilityNodeInfoCompatLimited types
iOSaccessibilityValueFlexible
FlutterSemantics → valueFlexible
React NativeaccessibilityValueFlexible
XamarinNot supportedCan’t set accessibility value
Webaria-valuenow / aria-valuetextFlexible

7. State

Apps should provide an accessible state for elements, to ensure users of assistive technologies know their current state.

Screenshot of an app announcing a status message for screen reader users when loading or when errors are displayedScreenshot of an app announcing a status message for screen reader users when loading or when errors are displayed
FrameworkFeatureProsCons
AndroidsetStateDescription and AccessibilityNodeInfoCompatFlexibleRequires Android 11 (API 30)
iOSaccessibilityTraitsNo custom states
FlutterSemantics → stateNo custom states
React NativeaccessibilityStateNo custom states
XamarinNot supportedCan’t set accessibility state
WebARIA states, e.g. aria-selectedExtensive

8. Focus order

Apps should provide a logical focus order, allowing users of assistive technologies to navigate efficiently.

Screenshot of an app, showing the focus order using numbers displayed by Voice ControlScreenshot of an app, showing the focus order using numbers displayed by Voice Control
PlatformFeatureProsCons
AndroidsetAccessibilityTraversalBefore/AfterSingle adjustmentTwo API’s
iOSaccessibilityElementsFull controlKeep array up-to-date
FlutterSemanticsSortKeyFlexible
React NativeNot supportedCan’t change accessibility order
XamarinTabIndex and IsTabStopFlexibleKeep indices up-to-date
WebtabindexFlexibleKeep indices up-to-date

9. Focus change

Apps might need to move the focus of assistive technologies, to ensure users end up at the right element.

Screenshot of an app showing two scenarios where you might forcefully move the focus of assistive technologies, e.g. after scanning a QR-code or entering a pincodeScreenshot of an app showing two scenarios where you might forcefully move the focus of assistive technologies, e.g. after scanning a QR-code or entering a pincode
PlatformFeatureProsCons
AndroidAccessibilityEventTYPE_VIEW_FOCUSED
iOSUIAccessibility.NotificationscreenChanged or layoutChangedTwo types
FlutterNot supportedCan’t change accessibility focus
React NativesetAccessibilityFocus
XamarinSemanticExtensionsSetSemanticFocus3rd party library
Webtabindex / focus()Multiple options

10. Status messages

Apps should communicate major interface changes to assistive technologies, to ensure users know what's going on.

Screenshot of an app announcing a status message for screen reader users when loading or when errors are displayedScreenshot of an app announcing a status message for screen reader users when loading or when errors are displayed
PlatformFeatureProsCons
AndroidAccessibilityEventTYPE_ANNOUNCEMENT
or
View.announceFor Accessibility
Two options
iOSUIAccessibility.NotificationannouncementSimple
FlutterSemanticsServiceannounceEasy
React NativeAccessibilityInfoannounceForAccessibilityEasy
XamarinSemanticExtensionsAnnounceEasy3rd party library
Webaria-liveLess control

Conclusion

So, which framework do we recommend for accessible app development? Native frameworks provide the best accessibility support.

It may not be feasible to maintain two codebases and two development teams. Fortunately, cross-platform frameworks are expanding their support for accessibility features.

But beware, when using cross-platform frameworks you may not be able to access certain accessibility features due to layers of abstraction. If you want to develop the most accessible app, native is always the best choice.

FrameworkScoreVerdict
Android100%Full support
iOS100%Full support
Web100%Full support
Flutter90%Good support, lacks accessibility focus change
React Native90%Good support, lacks accessibility order change
Xamarin50-80%Mediocre support, lacks accessibility state/value, requires 3rd party libraries

Check our in-depth documentation for further guidance:

  • Android logoAndroid logo

    Android accessibility

    Android has an accessibility layer that helps users to navigate their Android devices more easily. By integrating accessibility features, you can improve your app's usability, particularly for users with disabilities.

    Learn about Android accessibility
  • iOS logoiOS logo

    iOS accessibility

    iOS has built-in accessibility features, accessibility APIs, and developer tools which provide an extraordinary opportunity to deliver a superior mobile experience to every user, including those with disabilities.

    Learn about iOS accessibility
  • Flutter logoFlutter logo

    Flutter accessibility

    Flutter is committed to supporting developers in making their apps more accessible. It has built-in support for accessibility features provided by the underlying operating system.

    Learn about Flutter accessibility
  • React Native logoReact Native logo

    React Native accessibility

    React Native has accessibility APIs which let your app accommodate all users. You can integrate apps with assistive technologies like the screen readers VoiceOver and TalkBack.

    Learn about React Native accessibility
  • .NET MAUI logo.NET MAUI logo

    .NET MAUI accessibility

    .NET MAUI has built-in semantics for accessibility and includes support for accessibility features, allowing developers to build inclusive apps.

    Learn about .NET MAUI accessibility
  • Xamarin logoXamarin logo

    Xamarin accessibility

    Xamarin has features to create apps which work well with accessibility features such as large type, high contrast, zoom in, screen reading, visual or haptic feedback cues, and alternative input methods.

    Learn about Xamarin accessibility

Credits

This article is an adapted version of the talk Jan Jaap de Groot gave at the #id24 conference on 21 September 2023. You can watch the recording for more details.

Video: Jan Jaap de Groot / Native mobile accessibility testing #id24 2023 Video: Jan Jaap de Groot / Native mobile accessibility testing #id24 2023