I am talking to a friend on the phone and the conversation is somewhat incomplete but we decide to hang up. Before hanging up, he says "I'll see you tomorrow". Would it be grammatical to reply,

OK, talk to you then then!

The two thens are not a typo, in fact that's my whole question.


Sure, it’s perfectly fine, normal even. It means that you shall therefore speak with them at that time. “Therefore” and “at that time” are two different kinds of then.


The thing is, is that idiomatically many people often do say things like this. My example has been explored here before. I think it's because the thing is has become lexicalised as a single item (just an introduction/interjection without a "functional" verb), but you can make up your own mind.

OP's case is much simpler. The first "then" means "at that time", and refers to when you'll speak again. The second means "in that case", which implicitly refers to whatever was established by the preceding dialogue.

Because the two instances of the word have completely different senses, there's absolutely nothing unusual about the repetition. In practice they normally wouldn't even sound the same, since the first would be stressed, the second not.