DKIM Record In DNS

Posted September 15, 2013 9.5k views
I've been unable to add a DKIM using the Digital Ocean DNS control panel because it exceeds 256 characters. v=DKIM1; p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAzLoiRSkXBbu83qXedscb gC7d4kevZRj7eO54SLo4hU/T2kZ1XmuJ203zsa8ejPgG6es7jiSHPOe4OGD5h5Xb 9DkRyOhkTEPe1XjUWU6kXGRy18nHG0iR0cNiNX1VPpFULHEQulkt/mFwN8MDm9Tv YryHcufZ6nM75aJu4an+x4r8lINVd+3GL4SGYhyfDdvH8d3rOefJ1TmjbCcqwkMB rXGjG4PllMhYkTylqCgjST5HQyGrWh6MbyIG0vQv5czf4SehzWeD7qP+0CYEIHW9 BFwZD4OmmZc4DljMaw4x9yIgT41b1XaKnEnw6tnyepJ6CcjR6eoHN0qEioAxFcwu HwIDAQAB Does anyone know if there is a way of getting this to work

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Submit an Answer
10 answers
you have extra white space in there, get rid of the new line after the ";" and you will also need to put it in quotes
I've removed all the white space but the record is still 403 characters long. I'll log a support ticket and see what DO say

Thanks for your help

Were you able to get this figured out? I'm sure I'm not the only one that's curious to know if there's a solution.
Try decreasing your DKIM key's size to <255. Let me know if that works.
Hi, I got a response from DO support to say they don't support more than 256 characters and that I'd have to make my own DNS servers using droplets.

Unfortunately I cannot change the DKIM key on the current version of Kerio Connect which is the software i am using for email. The key is generated automatically and I have no control
thanks I'll do that. Don't get me wrong though I am not complaining, I've moved all the virtual servers from Media Temple and couldn't be happier
use 1024 keys?

Anybody figure this out? The key that I’ve generated from Mandrill is 236 characters. I’ve pasted it in with quotes around it. Seems to not be validating though.

I had the same issue following

There were new lines in the key, they had to be removed. Also, one of the new lines had a backslash before it which was treated as new line by digitalocean. The key was 238 characters long and fit alright, so those who have longer keys might try following instruction I followed or remove extra stuff - only the data between quotes should go into the field + new lines and extra quotes should be removed. Example


mail._domainkey IN TXT “v=DKIM1; k=rsa; ” “p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC5N3lnvvrYgPCRSoqn+awTpE+iGYcKBPpo8HHbcFfCIIV10Hwo4PhCoGZSaKVHOjDm4yefKXhQjM7iKzEPuBatE7\
O47hAx1CJpNuIdLxhILSbEmbMxJrJAG0HZVn8z6EAoOHZNaPHmK2h4UUrjOG8zA5BHfzJf7tGwI+K619fFUwIDAQAB” ; —– DKIM key mail for

TXT field should have the following:


by Popute Sebastian Armin
This tutorial will focus on installing and configuring OpenDKIM: an open source implementation of the DKIM sender authentication system.