# What is the maximum key size for a 128 bit AES?

What is the maximum key size for AES 128, Will using a key greater than maximum gives extra security or error? Is there a minimum key size?

Suppose a key is 128 bit, does it means The key is of length 16characters

Suggest me a good password to key function.

• 1. 128 bits is the largest 128 bit key. Conversely, the smallest 128 bit key is 128 bits. 2. Characters are not always 8 bits so there is no translation between key size and number of characters 3. The fastest function to transform a password into a key is to ignore the password and return the zero key. This is good if speed is the important measure. Feb 28, 2017 at 19:06
• An AES-128 key consists of exactly 128 bits / 16 bytes, no more, no less. Feb 28, 2017 at 19:34
• Q: Will using more than four wheels on my car give me more stability or error? A: the question is nonsense because my car doesn't even have a spot to put more than 4 wheels. I'd have to totally redesign the car. Feb 28, 2017 at 23:14

Despite similarities, it is really important to understand that passwords and cryptographic keys should not be carelessly conflated. Some important contrasts:

• Passwords are normally selected by human beings according to their whims. Cryptographic keys are meant to be randomly generated by an algorithm.
• Passwords are usually intended to be memorized by human beings. A strong cryptographic key cannot generally be memorized—they're too random and complex—and thus generally stored in a secure device. In the parlance of multi-factor authentication, passwords are "something you know" while cryptographic keys are "something you have."
• Passwords have to be text that human beings can manually input into their devices. Cryptographic keys are fundamentally binary data (despite being sometimes serialized and deserialized as text) and are generally not meant to input manually.

I say all this because your question really comes down to a lack of understanding of these differences. AES doesn't use passwords, it uses keys. AES-128 keys are fixed-length binary data; they don't really have "characters" because they're not text. As others have said, the maximum key size for AES-128 is the same as the minimum and only key size: 128 bits.

• I'm open to that, but many (if not most) bcrypt APIs in practice don't seem oriented to getting out key material, instead just giving you an /etc/shadow-style encoded blob that you'd have to parse the key out of. Feb 28, 2017 at 19:43