Custom keyboards are App Extensions that can run system-wide in iOS 8 and up.
A custom keyboard replaces the system keyboard for users who want capabilities such as a novel text input method or the ability to enter text in a language not otherwise supported in iOS. The essential function of a custom keyboard is simple: Respond to taps, gestures, or other input events and provide text, in the form of an unattributed NSString object, at the text insertion point of the current text input object.
Before iOS 8, developers are able to provide custom keyboards with custom keys within their application only. With iOS 8
, Apple has made it possible to create custom keyboards that will be able to be used system wide in other apps. Now it is possible to ship a custom keyboard with iOS app and users will be able to choose it as the keyboard to use for every app that requires text input.
Source