“I'd better lock it up just in case.”
You're leaving your office to go out to lunch with a coworker. You brought a valuable item to work today. You don't think anyone would steal it in your office, but you want to be careful. You say this to yourself.
I'd better lock it up just in case.
Doing something "in case" means that you do it to prepare for a possible result.
For example, if you give someone an extra drink "in case", it's because you think they might get really thirsty.
So you can say "(do something) in case (something happens) like this:
Here. Write down the phone number in case you can't find it.
Or you can say "just in case". To do something "just in case" means that you're doing it even though you don't think it's needed. You're doing it to be extra careful:
Use "I'd better ___" to express something that you should do soon.
I'd better get going, or I'll be late.
Compared to "I should ___" this phrase sounds more urgent. Use it for things that you need to do quite soon.
You "lock" a door, a window, a safe, etc. But when you're talking about the things inside that you're protecting, you say "lock up ___" or "lock ___ up":
Make sure to lock up the house before you go out.
She locked up her wallet and cell phone in the hotel safe before going out to the pool.