He jumped OVER a box kept NEAR the tree to catch the cute cat.
The word "near " can be used in many ways. It can be an adjective, a preposition, a verb or an adverb.
Here "near" is used a preposition, as it is positioned before the noun "the tree". It indicates a place (connecting to) relative to the tree.
The word "over" can be used as an adverb or a preposition.
Here it is used as a preposition as it is positioned before the noun "a box".
It indicates the position above the box.