The paper deals with the heating of electrons and current rectification in contact, which is located in an alternating electromagnetic field. It was found that the electrical component of the microwave (UHF) waves inside the p-n-junction was curved. This leads to the perpendicular component of the electric field of the microwave wave. This component modulates the height of the potential barrier with the frequency of the microwave. In the p-n-junction, straightening microwave current occurs. It is shown that the rectifying contact in the microwave electromagnetic field is always an electromotive force. This is due to carrier heating and straightening microwave current. It is shown that electron heating and straightening of the microwave power will lead to higher ideality factor of the diode.