Welcome to the forum
Reads like you have eliminated most other things as the problem.
Your 2005 falls in the 2004-2006 range for bad exhaust valve seats on the 3.0l Ranger engines.
A TSB was issued for that: http://ww2.justanswer.com/uploads/BO...ssfire_tsb.pdf
First step would be to remove all 6 spark plugs and then do a compression test for all 6 cylinders, engine should be cold.
See where #4 is at when you have the average from the other 5
You can add a teaspoon of oil to #4, #5, #6 and then redo compression test on all 3
Compression numbers will go up on all 3 but not as much on #4, because the oil seals the rings, but not the valves, so if #4 is still low then it is a valve issue not a ring issue, kinda like a poorman's leakdown test
A leakdown test on #4 would confirm bad exhaust valve seat because you could hear air escaping from #4 by listening at the tail pipe, you could do this first if you have the means
What happens with this is that the exhaust valve seat would start to recess/sink into the head so there was no longer a good seal between valve and seat, so compression in that cylinder would go down enough to cause a misfire at lower RPMs, as RPMs increase there is less time for the air in the cylinder to escape thru the exhaust valve seat gap, so compression increases enough for cylinder to fire.
If you do have this problem then BOTH heads need to have new seats installed or swap for new heads.
This didn't happen to ALL 2004-2006 3.0l Rangers, so there was no recall, Ford, of course, doesn't say why it happens on some, but my guess would be some seats were out of spec and were installed, this is why BOTH heads should be repaired/exchanged, because other exhaust valve seats in your engine will be from same batch as the one that is failing at this time.
And in the compression test you may find 1 or 2 other cylinders that are lower but not as low as #4, those seats are also failing but haven't recessed enough to cause a problem yet.