Why would my guy friend of 3 1/2 years block me out of the blue?

Anonymous
A couple of years ago, me and my guy friend said we liked each other. Nothing ever happened apart from inappropriate messages (from him). He has a partner. A couple of months later we decided to be just friends. We have been messaging as friends since but not as frequent. About a month ago, we had a very lengthy friendly conversation, the first in months, but then he said some things he shouldn’t have and that he still likes me. A couple of weeks later, he messaged me at 1 in the morning. Now he’s blocked me out of the blue.
Why would my guy friend of 3 1/2 years block me out of the blue?
4 Opinion