In most direct meaning of these words, I cannot see any difference.
Both have however various "use cases", then you have to choose the appropriate one, for example:
1)
заходить = to visit
Да, он заходил ко мне на прошлой неделе.
2)
входить = to take part
Подметать двор не входит в мои обязанности.