Accessibility

Make your apps accessible to everyone, including people with disabilities.

Overview

Accessibility features help a wide range of people interact with their devices. For many, accessibility is a necessity. For others, it is practicality. (For example, closed captions can be necessary for someone who is deaf or hard of hearing, but also useful for someone watching a video in a noisy environment.) Whether you’re developing a new app, or updating an existing one, consider the needs of all the people who may use your app. People can personalize their devices by choosing which accessibility features give them the best user experience.

By designing your app with accessibility in mind, you make it possible for everyone to enjoy your app. To help simplify this, there are four accessibility domains to keep in mind when thinking about your users:

  • Vision, a person may be blind, color blind, or have a vision challenge that makes focusing difficult.

  • Hearing, a person may be deaf, have partial hearing loss, or they may have difficulty hearing sounds within a certain range.

  • Physical and motor skills, a person with reduced mobility may have difficulty holding a device or tapping the interface.

  • Learning and literacy, a person may have difficulty remembering a sequence of steps or they may find an overly complex user interface too hard to process and manage.

The four accessibility domain symbols for vision, hearing, physical and motor skills, and literacy and learning. From left-to-right, An eye icon, a speaker icon, an open hand icon, and an icon of upper and lowercase A characters.

iOS provides a wealth of accessibility features—such as VoiceOver, Switch Control, and Assistive Touch—that your app can tap into simply by using standard UIKit controls. Resources are available to help you easily utilize these built-in tools.

Topics

First Steps

UIAccessibility

A set of methods that provide accessibility information about views and controls in an app's user interface.

UIAccessibilityContainer

A set of methods that view subclasses use to make subcomponents accessible as separate elements.

Supporting VoiceOver in Your App

Learn how to make your iOS app more accessible to users who are blind or have low vision by adding VoiceOver support.

Behaviors

UIAccessibilityFocus

An informal protocol that provides a way to find out whether an assistive technology, such as VoiceOver, is focused on an accessible element.

protocol UIAccessibilityIdentification

Methods that associate a unique identifier with elements in your user interface.

protocol UIAccessibilityReadingContent

Methods to implement on an object that represents content that is intended to be read by users, such as a book or an article.

protocol UIAccessibilityContentSizeCategoryImageAdjusting

Methods to determine when to adjust images for different content size categories.

Actions

UIAccessibilityAction

A set of methods that accessibility elements can use to support specific actions.

class UIAccessibilityCustomAction

A custom action to be performed on an accessible object.

Delivering an Exceptional Accessibility Experience

Make improvements to your app’s interaction model to support assistive technologies such as VoiceOver.

Elements

class UIAccessibilityElement

Encapsulates information about an item that should be accessible to users with disabilities, but that isn’t accessible by default.

protocol UIScrollViewAccessibilityDelegate

A set of methods you can implement to provide accessibility information for a scroll view.

protocol UIPickerViewAccessibilityDelegate

A set of methods you can implement to provide accessibility information for individual components of a picker view.

Containers

protocol UIAccessibilityContainerDataTable

Methods that convey information about the contents of a table.

protocol UIAccessibilityContainerDataTableCell

Methods that provide the location of a cell in a table.

enum UIAccessibilityContainerType

Constants indicating the type of content stored in a data-based container.

Navigation

class UIAccessibilityCustomRotor

A context-sensitive function that helps Voice Over users find the next instance of a related element.

class UIAccessibilityCustomRotorItemResult

A target element referenced by a custom rotor.

class UIAccessibilityCustomRotorSearchPredicate

The search parameters that help determine the next matching custom rotor item result.

Drag and Drop Support

class UIAccessibilityLocationDescriptor

An accessibility descriptor for a specific geometric point of interest within a view, for use by assistive technologies.

Notifications

Notification Names

Contains the names of notifications generated by the accessibility system.

Conversions

static func convertToScreenCoordinates(CGRect, in: UIView) -> CGRect

Converts the specified rectangle from view coordinates to screen coordinates.

static func convertToScreenCoordinates(UIBezierPath, in: UIView) -> UIBezierPath

Converts the specified path object to screen coordinates and returns a new path object with the results.

Convenience Functions

static func focusedElement(using: UIAccessibility.AssistiveTechnologyIdentifier?) -> Any?

Returns the element that is currently focused by the specified assistive technology.

static var hearingDevicePairedEar: UIAccessibility.HearingDeviceEar

Returns the current pairing status of MFi hearing aids.

struct UIAccessibility.HearingDeviceEar

Constants that specify how a hearing device is being used.

static func registerGestureConflictWithZoom()

Warns users that application-specific gestures conflict with the system-defined Zoom accessibility gestures.

static func requestGuidedAccessSession(enabled: Bool, completionHandler: (Bool) -> Void)

Transitions the app to or from Single App mode asynchronously.

static func zoomFocusChanged(zoomType: UIAccessibility.ZoomType, toFrame: CGRect, in: UIView)

Notifies the system that the app’s focus has changed to a new location.

Capabilities

static var isAssistiveTouchRunning: Bool

Returns a Boolean value indicating whether the system preference for AssistiveTouch is enabled.

static var isVoiceOverRunning: Bool

Returns a Boolean value indicating whether VoiceOver is running.

static var isSwitchControlRunning: Bool

Returns a Boolean value indicating whether Switch Control is enabled.

static var isShakeToUndoEnabled: Bool

Returns a Boolean value indicating whether the system preference for Shake to Undo is enabled.

static var isClosedCaptioningEnabled: Bool

Returns a Boolean value indicating whether closed captioning is enabled.

static var isBoldTextEnabled: Bool

Returns a Boolean value indicating whether bold text is enabled.

static var isDarkerSystemColorsEnabled: Bool

Returns a Boolean value indicating whether darken colors is enabled.

static var isGrayscaleEnabled: Bool

Returns a Boolean value indicating whether grayscale is enabled.

static var isGuidedAccessEnabled: Bool

Returns a Boolean value indicating whether the app is running in Guided Access mode.

static var isInvertColorsEnabled: Bool

Returns a Boolean value indicating whether inverted colors is enabled.

static var isMonoAudioEnabled: Bool

Returns a Boolean value indicating whether system audio is set to mono.

static var isReduceMotionEnabled: Bool

Returns a Boolean value indicating whether reduce motion is enabled.

static var isReduceTransparencyEnabled: Bool

Returns a Boolean value indicating whether reduce transparency is enabled.

static var isSpeakScreenEnabled: Bool

Returns a Boolean value indicating whether speaking the screen is enabled.

static var isSpeakSelectionEnabled: Bool

Returns a Boolean value indicating whether speaking the selection is enabled.

See Also

User Interactions

Touches, Presses, and Gestures

Encapsulate your app's event-handling logic in gesture recognizers so that you can reuse that code throughout your app.

Drag and Drop

Bring drag and drop to your app by using interaction APIs with your views.

Focus Interactions

Navigate the interface of your UIKit app using a remote or game controller.

Peek and Pop

Use 3D Touch input to display custom previews and actions for your content.

Keyboard and Menus

Handle keyboard input, and display a menu of custom actions.