Hebrews 12:7-8 It is for discipline that you have to endure. God is treating you as sons. For what son is there whom his father does not discipline? If you are left without discipline, in which all have participated, then you are illegitimate children and not sons.
How does a child learn to do what’s right? They learn through the example their parents give, yes, but they also learn through correction and discipline when they do the wrong things. By being taught what the rights things are and disciplined over the wrong things, a child can grow into maturity, knowing right from wrong.
How does a Christian learn what God wants? We have Jesus as our example and we have the commandments to guide us in what’s right. But when we stray from what God has taught us doesn’t He also correct us? Doesn’t He sometimes put us back on the right track because He loves us? There’s a big difference between punishment and discipline. Some have the view that God is up above watching for us to mess up so He can take His vengeance on us. That action out of anger would be punishment. But God doesn’t punish those He loves. He disciplines them.
The truth is, we may not always even know we’re being disciplined. The Father may remove something from us that isn’t good for us in a way that provides correction. We may not even have been aware of what happened. God may also put people in our lives at certain times that give some correction. Whatever the method, God disciplines because He loves. Any parent who provides no guidance and no boundaries to their children does not love them. If a child is allowed to destroy themselves, the parent has no love for them. But our Father does love us, and He loves us enough to make sure we’re everything we’re supposed to be.