Fully Homomorphic Encryption: Going from an integer to bits
One possible solution for you is to use a Bit Extraction Circuit. The references are framed in terms of MPC but they should be applicable. If you want something more specific/efficient to homomorphic encryption, it will depend on the scheme.


O. Catrina and S. Hoogh, “Improved primitives for secure multiparty
integer computation,” in Security and Cryptography for Networks
(SCN’10), ser. LNCS, vol. 6280. Springer, 2010, pp. 182–199.
O. Catrina and A. Saxena, “Secure computation with fixed-point
numbers,” in Financial Cryptography and Data Security (FC’10), ser.
LNCS, vol. 6052. Springer, 2010, pp. 35–50.
I. Damgard, M. Fitzi, E. Kiltz, J. B. Nielsen, and T. Toft, “Unconditionally secure constant-rounds multi-party computation for equality,
comparison, bits and exponentiation,” in TCC’06, ser. LNCS, vol. 3876.
Springer, 2006, pp. 285–304.