I just replaced one in my 2007 Ram last week. The guy at a NAPA store suggested buying a factory part instead of aftermarket due to reliability issues. $38 at the dealer.
There are TWO senders near the oil filter. The upper one is the oil pressure sender. It is mounted horizontally and points toward the radiator. A 1 1/16" deep socket fits the hex on it. A 6 inch extension and a 1/2" drive ratchet cleared the lower radiator hose. It is fine thread so be ready for that.
The hardest part was removing the retainer to get the wire plug off. There is a sliding red plastic tab that pushes up from the bottom to release the wire plug. I used a long standard flat screwdriver.
Good luck.