Text message (SMS) security codes used for two-factor authentication are always 6 digits long. To set up text message (SMS) two-factor authentication, you can either use a mobile number that’s already been added to your account or add a new number.
https://www.facebook.com/help/909243165853369/?helpref=hc_fnav

