Skip to main content
minor typos
Source Link
MGOwen
  • 7.4k
  • 13
  • 60
  • 72

Just use varchar(50). Longer emailemails are crap all the, every time.

Just look how long 50 chars is:

peoplewithanemail@ddressthislongjustuseashorterone

If you allow 255 character emails:

  • Displaying them can mess up your UI (at best they will be cut off, at worst they push your containers and margins around) and
  • Malicious users can do things with them you can't anticipate (like those cases where hackers used a free online API to store a bunch of data)

(Statistics show that no-one actually enters more than about 50 chars for a legit email address, see e.g.: pageman's answer https://stackoverflow.com/a/1199245/87861)

Just use varchar(50). Longer email are crap all the time.

Just look how long 50 chars is:

peoplewithanemail@ddressthislongjustuseashorterone

Just use varchar(50). Longer emails are crap, every time.

Just look how long 50 chars is:

peoplewithanemail@ddressthislongjustuseashorterone

If you allow 255 character emails:

  • Displaying them can mess up your UI (at best they will be cut off, at worst they push your containers and margins around) and
  • Malicious users can do things with them you can't anticipate (like those cases where hackers used a free online API to store a bunch of data)

(Statistics show that no-one actually enters more than about 50 chars for a legit email address, see e.g.: pageman's answer https://stackoverflow.com/a/1199245/87861)

added example
Source Link
MGOwen
  • 7.4k
  • 13
  • 60
  • 72

Just use varchar(50). Longer email are crap all the time.

Just look how long 50 chars is:

peoplewithanemail@ddressthislongjustuseashorterone

Just use varchar(50). Longer email are crap all the time.

Just use varchar(50). Longer email are crap all the time.

Just look how long 50 chars is:

peoplewithanemail@ddressthislongjustuseashorterone

Source Link
Nicolas Manzini
  • 8.5k
  • 6
  • 68
  • 83

Just use varchar(50). Longer email are crap all the time.