Magic Keyboard: The ultimate guideEverything you need to know to set up and use the Magic Keyboard on your Mac, iPhone, iPad, or Apple TV.
The Magic Keyboard comes with new Macs but it also works with old Macs, and with iPhone, iPad, and Apple TV. It connects over Bluetooth, so you can pair it with anything and everything that supports that standard, but Apple's also made it pair instantly over Lightning with the Mac, making it faster and easier to get started than ever.
Updated December 2016: Reflects changes in macOS, iOS 10, and tvOS 10.
How to connect the Magic Keyboard to your Mac
How to connect the Magic Keyboard to your iPad
How to connect the Magic Keyboard to your iPhone
How to connect the Magic Keyboard to your Apple TV
How to connect the Magic Keyboard to your Mac
If you buy a new Retina 4K iMac or Retina 5K iMac it'll come with a Magic Keyboard pre-paired and ready to go. If you have an existing Mac, though, it's incredibly easy to pair a new Magic Keyboard to is and get going as well.
How to pair...
Source:
Magic Keyboard: The ultimate guide