Not sure if it started after upgrade to the latest version of MacOS Sierra 10.12, but I feel like so.
My laptop loses connection to wireless keyboard very often and does not reconnect automatically. Turning on and off does not help.
I tried to find an explanation and possible solution, and the only hint I found was to re-connect the keyboard.
This is how you do it:
Call Keyboard preferences window by typing in [CMD] +[Space] -> keyboard[
2. Click the [Setup Bluetooth Keyboard] in the bottom corner of the Dialog
<img class="aligncenter size-medium wp-image-404" src="http://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.39.42-300x260.png" alt="" width="300" height="260" srcset="https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.39.42-300x260.png 300w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.39.42-768x665.png 768w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.39.42-1024x886.png 1024w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.39.42.png 1340w" sizes="(max-width: 300px) 100vw, 300px" />
3. Observe your joined but disconnected keyboard in the list
<img class="aligncenter size-medium wp-image-403" src="http://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.39.52-300x192.png" alt="" width="300" height="192" srcset="https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.39.52-300x192.png 300w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.39.52-768x490.png 768w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.39.52.png 968w" sizes="(max-width: 300px) 100vw, 300px" />
4. Press the (x) on the right side of the list item with you keyboard name and remove it from the list
5. Turn Off your bluetooth keyboard by long holding the power button
6. Turn On the keyboard and keep holding the power button — it should stop started blinking 2 short blinks — pause — 2 short blinks — pause …
7. Observe the keyboard appeared in the list and there is a [Pair] button on the right
<img class="aligncenter size-medium wp-image-408" src="http://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.42.19-300x187.png" alt="" width="300" height="187" srcset="https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.42.19-300x187.png 300w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.42.19-768x478.png 768w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.42.19.png 958w" sizes="(max-width: 300px) 100vw, 300px" />
8. Press the [Pair] button while still holding the power button and wait until the keyboard gets connected — you will see a Dialog with a secret code, exactly as you see when connection a new bluetooth device.
<img class="aligncenter size-medium wp-image-407" src="http://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.42.49-300x170.png" alt="" width="300" height="170" srcset="https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.42.49-300x170.png 300w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.42.49-768x436.png 768w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.42.49-1024x582.png 1024w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.42.49.png 1046w" sizes="(max-width: 300px) 100vw, 300px" />
9. At the moment, your bluetooth keyboard is visible and you must type in the secret code using this remote keyboard!
<img class="aligncenter size-medium wp-image-406" src="http://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.43.06-300x161.png" alt="" width="300" height="161" srcset="https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.43.06-300x161.png 300w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.43.06-768x413.png 768w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.43.06-1024x550.png 1024w, https://rodush.com/wp-content/uploads/2017/01/Screen-Shot-2017-01-16-at-10.43.06.png 1314w" sizes="(max-width: 300px) 100vw, 300px" />
That it it, you keyboard is not connected and visible again.
Alas… from time to time, when the laptop is disconnected for quite long time, for example, after the weekend, I still have this issue that keyboard is lost/disconnected, so I have to repeat aforementioned steps again and again. Up to now, I still don’t understand what is the issue and how to solve it permanently.