Most budgies will try to bluff or warn you by jabbing at you with the beak to tell you to get away, before they actually bite. But if you do not heed this, then next comes the bite or bites. The beak can be formidable and cause severe pain, especially if it belongs to a budgie female, but it is also used to explore and check out things. Let's say you ask budgie to step up on your finger and budgie leans toward finger with its beak, don't think it is going to bite and jerk your hand away. It may be wanting to test the solidity of this new perch to make sure it is safe first before stepping up on it.
Fingers coming through the cage bars is an invitation to get bitten.
Budgies also fear hands or things above their heads swooping down on them. That really scares them. Talking in a smooth soft voice is also soothing. Tell your budgie what you are doing before you actually do it. When you come home, say hello to your budgie, when you leave say good bye, just as you would to any good friend.