What are DNS TXT records and why are they needed

TXT records were originally intended to provide an option to place arbitrary user-comments.

Now, they are generally used for the SPF anti-spam system.


TXT records were originally intended just to store arbitrary (small) amounts of text as labels for DNS data.

However since they were the only free-form record type specified for use in DNS they were subsequently misused greatly as a dumping ground for any old crap that didn't have its own resource record type (i.e. SPF).

SPF does now have its own record type, but legacy systems still prefer the old TXT format.