"Contrary to what we normally think, ungodliness and wickedness are not the same. A person may be a nice, respectable citizen and still be an ungodly person. The apostle Paul wrote in Romans 1:18, "The wrath of God is revealed from heaven against all ungodliness and unrighteousness." Note that Paul distinguishes ungodliness from unrighteousness. Ungodliness describes an attitude toward God, while unrighteousness refers to sinful actions in thought, word, or deed. An athiest or avowed secularist is obviously an ungodly person, but so are a lot of morally decent people, even if they say they believe in God.
Ungodliness may be defined as living one's everyday life with little or no thought of God, or of God's will, or of God's glory, or one's depenence on God. You can readily see, then, that someone can lead a respectable life and still be ungodly in the sense that God is essentially irrelevant in his or her life. We rub shoulders with such people every day in the course of our ordinary activities. They may be friendly, courteous, and helpful to other people, but God is not at all in their thoughts. They may even attend church for an hour or so each week but then live the remainder of the week as if God doesn't exist. They are not wicked people, but they are ungodly." - Jerry Bridges, Respectable Sins, pp. 53-54.