What are the conditions for removing excommunication of a married priest? If a Catholic priest leaves his priesthood and marries a woman, he is automatically excommunicated. 
Does the Catholic Church recognize his marriage? He marries outside of the Chuch so his marriage is not sacramental but it might still be recognized as it is for atheists or other Christians.

What can the priest do if he realizes his wrong decision and wants to go back to the priesthood or at least start leaving a sacramental life? Let's say he has children and is validly married according to the secular law.

I know deacons must stay away from a marital act with their wives and live in celibacy. So I'm expecting similar requirements for an excommunicated priest who at least wants back because of sacraments. Can he even live with his wife as it might be considered cohabitation or would he be allowed to remarry in the Catholic Church so he can live with his wife?
If a man is ordained, he is unable to validly marry in the Church:


  Those in sacred orders invalidly attempt marriage.


(Code of Canon Law, canon 1087)

But he is not (as AthanasiusOfAlex points out) excommunicated by that fact. He is suspended from carrying out his priestly office:


  A cleric who attempts marriage, even if only civilly, incurs a latae sententiae suspension. If he does not repent after being warned and continues to give scandal, he can be punished gradually by privations or even by dismissal from the clerical state.


(Canon 1394)

Thus it is expected that the man will separate from his putative wife and presumably get a civil divorce. In some ways he is in a similar situation to one who has civilly divorced and "remarried" (i.e., one who who lives in concubinage). (I've answered a question about that very possibility.)

There is no way to validate the putative marriage by convalidation or radical sanation while still being a priest. He can request an indult (formal permission) from the Holy See to become laicized, and then another to marry after that.

He cannot go on living "as brother and sister" with his putative spouse. This is an option for lay people. But if a priest were to do so, he'd invite scandal, the possibility of leading people into evil (cf. Catechism of the Catholic Church, para. 2284.) In this case, the scandal would be the potential belief that the Catholic Church was actually OK with the man's sin, and therefore that this wasn't a big deal, and maybe that it was not really a sin in the Church's eyes. Thus he will need to leave, and make it clear that he is not married to this woman.

If he is laicized, he can (with permission) validly marry. Even if he remains a priest, though, the man is still responsible for his minor children, and will have to make some sort of arrangement for their welfare. Since the bishop is in turn responsible for him, he will probably suggest that the priest request to be laicized, allowing him to raise a family as if he were a married layman.

Either way, once the man's spiritual situation is regularized (i.e. once he becomes again either an active priest in good standing or a laicized priest validly married), he should confess the sin (of fornication) which he has committed, and return to full spiritual health.