While playing around with Unity, I noticed that when I add a cube with a rigidbody component on top of a ground (plane or just another cube), it’s y position transform always drops by 0.02 when you hit play. Why does it do that? Is it some internal setting or something?
Go to Edit - Project Settings - Physics. There you find the Min Penetration for Penalty. That’s basically a precision setting for the physics engine. You can lower that value if you need more precision, for the cost of performance.
You could also increase the collider slightly to avoid the visual effect.